А шифр не слабо крякнуть?

и задачки для интервью.
User avatar
Chapaev
Новичок
Posts: 96
Joined: 19 Jun 2001 09:01
Location: Canada

А шифр не слабо крякнуть?

Post by Chapaev »

Это упражнение приведено в книжке "The code Book" by Simon Singh, Anchor Books.
Текст английский, шифр - простой моноалфавитный, подстановочный. У меня решение отняло 25 минут, если не считать набор текста в файл и написание простенькой програмки, считающей частоту символов в текстовом файле.

BT JPX RMLX PCUV AMLX ICVJP IBTWXVR CI M LMT'R PMTN, MTN YVCJX CDXV MWMBTRJ JPX AMTNGXRJBAH UQCT JPX QGMRJXV CI JPX YMGG CI JPX HBTW'R QMGMAX; MTN JPX HBTW RMY JPX QMVJ CI JPX PMTN JPMJ YVCJX. JPXT JPX HBTW'R ACUTJXTMTAX YMR APMTWXN, MTN PBR JPCUWPJR JVCUFGXN PBL, RC JPMJ JPX SCBTJR CI PBR
GCBTR YXVX GCCRXN, MTN PBR HTXXR RLCJX CTX MWMBTRJ
MTCJPXV. JPX HBTW AVBXN MGCUN JC FVBTW BT JPX MRJVCGCWXVR, JPX APMGNXMTR, MTN JPX RCCJPRMEXVR. MTN JPX HBTW RQMHX, MTN RMBN JC JPX YBRX LXT CI FMFEGCT, YPCRCXDXV RPMGG VXMN JPBR YVBJBTW, MTN RPCY LX JPX BTJXVQVXJMJBCT JPXVXCI, RPMGG FX AGCJPXN YBJP RAMVGXJ, MTN PMDX M APMBT CI WCGN
MFCUJ PBR TXAH, MTN RPMGG FX JPX JPBVN VUGXV BT JPX HBTWNCL. JPXT AMLX BT MGG JPX HBTW'R YBRX LXT; FUJ JPXE ACUGN TCJ VXMN JPX YVBJBTW, TCV LMHX HTCYT JC JPX HBTW JPX BTJXVQVXJMJBCT JPXVXCI. JPXT YMR HBTW FXGRPMOOMV WVXMJGE JVCUFGXN, MTN PBR ACUTJXTMTAX YMR APMTWXN BT PBL, MTN PBR GCVNR YXVX MRJCTBRPXN. TCY JPX KUXXT, FE VXMRCT CI JPX YCVNR CI JPX HBTW MTN PBR GCVNR, AMLX BTJC JPX FMTKUXJ PCURX; MTN JPX KUXXT RQMHN RMBN, C HBTW, GBDX ICVXDXV; GXJ TCJ JPE JPCUWPJR JVCUFGX JPXX, TCV GXJ JPE ACUTJXTMTAX FX APMTWXN; JPXVX BR M LMT BT JPE HBTWNCL, BT YPCL BR JPX RQBVBJ CI JPX PCGE WCNR; MTN NMER CI JPX NMER CI JPE IMJPXV GBWPJ MTN UTNXVRJMTNNBTW MTN YBRNCL, GBHX JPX YBRNCL CI JPX WCNR, YMR ICUTN BT PBL; YPCL JPX HBTW TXFUAPMNTXOOMV JPE IMJPXV, JPX HBTW, B RME, JPE IMJPXV, LMNX LMRJXV CI JPX LMWBABMTR, MRJVCGCWXVR, APMGNXMTR, MTN CCJPRMEXVR;
ICVMRLUAP MR MT XZAXGGXTJ RQBVBJ, MTN HTCYGXNWX, MTN UTNXVRJMTNBTW, BTJXVQVXJBTW CI NVXMLR, MTN RPCYBTW CI PMVN RXTJXTAXR, MTN NBRRCGDBTW CI NCUFJR, YXVX ICUTN BT JPX RMLX NMTBXG, YPCL JPX HTBW TMLXN FXGJXRPMOOMV; TCY GXJ NMTBXG FX AMGGXN, MTN PX YBGG RPCY JPX BTJXVQVXJMJBCT. JPX
IBVRJ ACNXYCVN BR CJPXGGC.
PavelM
Уже с Приветом
Posts: 13316
Joined: 13 Jun 1999 09:01
Location: Yekaterinburg -> Montreal

А шифр не слабо крякнуть?

Post by PavelM »

После беглого взгляда на текст:

JPX = THE
JPXT= THEN
JPE = THY
JPXX= THEE
JPXVX = THERE
'R = 'S
PBR = HIS
BT = IN
RC = SO
JPCUWPJR = THOUGHTS
UQCT = UPON
FUJ = BUT
YVCJX = WROTE
YMGG = WALL
YPCRCXDXV = WHOSOEVER
UTNXVRJMTNBTW = UNDERSTANDING
APMBT = CHAIN
YPCL = WHOM

IN THE SAME HOUR CAME FORTH FINGERS OF A MAN'S HAND, AND WROTE OVER AGAINST THE CANDLESTICK UPON THE PLASTER OF THE WALL OF THE KING'S PALACE ...

Ну дальше сами ...
User avatar
Chapaev
Новичок
Posts: 96
Joined: 19 Jun 2001 09:01
Location: Canada

А шифр не слабо крякнуть?

Post by Chapaev »

<blockquote><font size="1" face="Arial, Verdana, Helvetica, sans-serif">quote:</font><hr>Originally posted by PavelM:
<strong>После беглого взгляда на текст:

IN THE SAME HOUR CAME FORTH FINGERS OF A MAN'S HAND, AND WROTE OVER AGAINST THE CANDLESTICK UPON THE PLASTER OF THE WALL OF THE KING'S PALACE ...

Ну дальше сами ...</strong><hr></blockquote>

Абсолютно точно!

Return to “Головоломки”