再來解碼吧!
今次玩的遊戲叫做 Stardew Valley,沒想到玩沒半個小時就有解謎了 > w<

FEZ 之後已經好久玩過解謎了,不知道這次謎題的難度如何?

以下是密碼文:
因為上次用紙筆記下來寫的,今次就聰明一點,寫個小程序來轉換文字吧。

首先將文字標籤起來:

準備

第一個字符記為「A」,新字符就用「B」,如此類推,沒什麼特別的。

標籤好後隨便選個語言寫( 這次就用 php 吧 ):
<?php

$a = "ab cdb efghij klb dkmmn cj kho njfp"
    . "\nhg lbcflg ab kqr sjl thscq js"
    . "\ncdb tkuubnp hs njf klb jgb ahcd"
    . "\nsjlbqc vkthw cdbg njf ahuu qbb"
    , "\ncdb clfb gkcflb js cdhq qwljuup";


echo strtr( $a, [
    "a" => ""
    , "b" => ""
    , "c" => ""
    , "d" => ""
] );

解題

首字個為 ab 是吧,通常句子首個詞是 ab 的字有 if / on / in / at ,先試試 if 會變成什麼樣子:
if cdf efghij klf dkmmn cj kho njfp
hg lfcflg if kqr sjl thscq js
cdf tkuufnp hs njf klf jgf ihcd
sjlfqc vkthw cdfg njf ihuu qff
cdf clff gkcflf js cdhq qwljuup
嗯,這裏值得留意的地方是最後一個字是 qff, q 沒有被轉換,但 ?ff 的字就只有 off 吧。也就是就 q 可能是 o ?
ae the efghij kle hkmmn tj kho njfp
hg letflg ae kqr sjl thstq js
the tkuuenp hs njf kle jge ahth
sjleqt vkthw theg njf ahuu qee
the tlfe gktfle js thhq qwljuup
沒能看出什麼呢,那麼先放著不管,來看看第二個詞 cdf ,三個字的詞是 the 的可能性很高,但這樣的話前一個詞的最後一個字必須是 e 為結尾, ?e 的詞有 be / me / we / he.
ae the efghij kle hkmmn tj kho njfp
hg letflg ae kqr sjl thstq js
the tkuuenp hs njf kle jge ahth
sjleqt vkthw theg njf ahuu qee
可是若果 cdb 是 the 的話,面後的 qbb 則會變為 ?ee ,好像沒有這個詞欸?

啊啊,這麼做不對,應該先從短的字著手,因為每個詞都必須有 a / e / i / o / u ,得先將響音猜出來。短的詞有 ab, cdb, klb, cj, kho, kqr, sjl, js, hs, njf, klb, jpb, njf, qbb 其中 b 這個字分別可以出現在任何地方,假設 b 為響音,那麼 ?bb 應該是什麼?

aa / ee / ii / oo / uu……只可能是 oo 吧?也就是説前面的 ab 可以是 to / do / go / no / so 這幾個,?oo 只能是 too / zoo,所以 to 有可能去掉…

如果 b -> o ,則 cdb -> XYo 。 grep "^\([^o]\)[^\1o]o\$" words.txt 得出的結果有:
abo ado ago apo avo azo bio bro dso duo dzo eco ego emo evo exo fro geo gio hao iso mho pho pro reo rho tao tho two udo ufo upo who ygo zho
其中可能的是 `two / who / duo / ego / pro ( 不過後面兩個不怎麼可能就是了…

如果首兩個詞是 we are 呢?
we are ?????? ??e r???? a? ??? ????
?? ?ea??? we ??? ??? ???a? ??
are ????e?? ?? ??? ??e ??e w?ar
???e?a ????? are? ??? w??? ?ee
are a??e ??a??e ?? ar?? ???????
w?ar,只可能是 wear 吧,不過這樣的話 b 就不可能是 e 了 Orz

好吧,搞不懂,明天再想!

===

今天又來挑戰解謎吧,我發現 qbb 這個模式的詞應該不多,又查了一下:
$ grep "^\([^\2\3]\)\(.\)\(\2\)$" words.txt
abb add aff all ann app ass att baa bee boo brr caa cee coo dee doo ebb eff egg ell err ess faa fee gee goo hmm hoo iff igg ill inn jee lee loo maa mee moo nee noo odd off pee poo ree roo see shh tee too umm vee wee woo zee zoo
結果真的沒有很多,這裏篩選出可能的詞有 odd / off / too / ill / zoo / all 吧。

這裏配對 ab cdb / qbb 的話,可能的組合有  ?l ??l / all, ?f ??f / off, ?o ??o / zoo, too 而 too 上次已經證明 oo 不對了。

啊,得先統計一下頻率才對:
a: 4
b: 16
c: 12
d: 7
e: 1
f: 7
g: 6
h: 9
i: 1
j: 11
k: 8
l: 9
m: 2
n: 5
o: 1
p: 3
q: 6
r: 1
s: 6
t: 3
u: 6
v: 1
w: 2
b, c, j 出現的次數最多,英文裏面 s 這個字也是最多的,已知 `b 不可能是 s 了。退而求其次取 c 為 s 的話:
F: abcq
T: ifso

if s?f ?????? ??f ????? s? ??? ????
?? ?fs??? if ?o? ??? ???so ??
s?f ????f?? ?? ??? ??f ??f i?s?
???fos ????? s?f? ??? i??? off
s?f s??f ??s??f ?? s??o o??????

f 好像不對,會不會是 it sit ,但 qbb 不能是 ?tt 欸。不過 cdb 怎麼看都是 the 啊,我試這從這裏出發看看……

F: abcdghju
T: wethyiol
we the ??yi?o ??e h???? to ?i? ?o??
iy ?et??y we ??? ?o? ?i?t? o?
the ??lle?? i? ?o? ??e oye with
?o?e?t ???i? they ?o? will ?ee
the t??e y?t??e o? thi? ???oll?
oye 這個跟本不是英文吧 Orz

唔…這個好像有點對了?這樣的話 y 大概可以稍後修正,將 thi? 轉成 this 看看~
F: abcdghjqu
T: wethyiosl

we the ??yi?o ??e h???? to ?i? ?o??
iy ?et??y we ?s? ?o? ?i?ts o?
the ??lle?? i? ?o? ??e oye with
?o?est ???i? they ?o? will see
the t??e y?t??e o? this s??oll?
噢噢!好像能行?!

s??oll? -> scroll?
F: abcdghjlquw
T: wethyiorslc

we the ??yi?o ?re h???? to ?i? ?o??
iy ret?ry we ?s? ?or ?i?ts o?
the ??lle?? i? ?o? ?re oye with
?orest ???ic they ?o? will see
the tr?e y?t?re o? this scroll?
?or -> for
F: abcdghjlqsuw
T: wethyiorsflc

we the ??yi?o ?re h???? to ?i? ?o??
iy ret?ry we ?s? for ?ifts of
the ??lle?? if ?o? ?re oye with
forest ???ic they ?o? will see
the tr?e y?t?re of this scroll?
for ?ifts -> for gifts
F: abcdghjlqstuw
T: wethyiorsfglc

we the ??yi?o ?re h???? to ?i? ?o??
iy ret?ry we ?s? for gifts of
the g?lle?? if ?o? ?re oye with
forest ??gic they ?o? will see
the tr?e y?t?re of this scroll?
we the ??yi?o ?re
這裏可以推論 ??yi?o 應該是群體名。

?re -> are
F: abcdghjklqstuw
T: wethyioarsfglc

we the ??yi?o are ha??? to ai? ?o??
iy ret?ry we as? for gifts of
the galle?? if ?o? are oye with
forest ?agic they ?o? will see
the tr?e yat?re of this scroll?
galle?? -> gallery, 所以 g 應該不是 y
F: abcdhjklnpqstuw
T: wethioarrysfglc

we the ???i?o are ha??r to ai? ro?y
i? ret?r? we as? for gifts of
the gallery if ro? are o?e with
forest ?agic the? ro? will see
the tr?e ?at?re of this scrolly
?agic -> magic
we the ???i?o are ha??r to ai? ro?y
i? ret?r? we as? for gifts of
the gallery if ro? are o?e with
forest magic the? ro? will see
the tr?e ?at?re of this scrolly
we as? for gifts -> we ask for gifts
F: abcdhjklnpqrstuvw
T: wethioarryskfglmc

we the ???i?o are ha??r to ai? ro?y
i? ret?r? we ask for gifts of
the gallery if ro? are o?e with
forest magic the? ro? will see
the tr?e ?at?re of this scrolly
這裏 o?e 有點難啊,owe ?但 w 已經有了… one
o?e -> one
F: abcdghjklnpqrstuvw
T: wethnioarryskfglmc

we the ??ni?o are ha??r to ai? ro?y
in ret?rn we ask for gifts of
the gallery if ro? are one with
forest magic then ro? will see
the tr?e nat?re of this scrolly
ret?rn -> return
F: abcdfghjklnpqrstuvw
T: wethunioarryskfglmc

we the ?uni?o are ha??r to ai? rouy
in return we ask for gifts of
the gallery if rou are one with
forest magic then rou will see
the true nature of this scrolly
唔…這個 rou 肯定是 you 吧,不過 for 也肯定是對的,會是 puns 嗎?

啊… r 不小心轉換了兩次了 Orz
F: abcdfghjklnpqrstuvw
T: wethunioaryyskfglmc

we the ?uni?o are ha??y to ai? youy
in return we ask for gifts of
the galleyy if you are one with
forest magic then you will see
the true nature of this scrolly
可是這樣的話 gallery 不就錯掉了麼? youy 應該是 you. 才對,也就是説有兩個 y 麼?

youy -> you.
F: abcdfghjklnqrstuvw
T: wethunioaryskfglmc

we the ?uni?o are ha??y to ai? you.
in return we ask for gifts of
the galley. if you are one with
forest magic then you will see
the true nature of this scroll.

題解

ha??y to ai? you -> happy to aid you
we the ?uni?o are happy to aid you.
in return we ask for gifts of
the galley. if you are one with
forest magic then you will see
the true nature of this scroll.
除了這個群體名 ?uni?o 之外都解出來了!

不過這個 galley 是什麼東東啊?

附上 php 源碼:
<?php

$cont = "ab cdb efghij klb dkmmn cj kho njfp"
    . "\nhg lbcflg ab kqr sjl thscq js"
    . "\ncdb tkuubnp hs njf klb jgb ahcd"
    . "\nsjlbqc vkthw cdbg njf ahuu qbb"
    . "\ncdb clfb gkcflb js cdhq qwljuup";

/*
foreach( count_chars( $cont, 1 ) as $char => $i )
{
    echo chr( $char ) . ": $i\n";
}
 */

$mappings = [
    "." => "."
    , "a" => "w"
    , "b" => "e"
    , "c" => "t"
    , "d" => "h"
    , "e" => "?"
    , "f" => "u"
    , "g" => "n"
    , "h" => "i"
    , "i" => "?"
    , "j" => "o"
    , "k" => "a"
    , "l" => "r"
    , "m" => "p"
    , "n" => "y"
    , "o" => "d"
    , "p" => "."
    , "q" => "s"
    , "r" => "k"
    , "s" => "f"
    , "t" => "g"
    , "u" => "l"
    , "v" => "m"
    , "w" => "c"
    , "x" => "?"
    , "y" => "?"
    , "z" => "?"
];

$m = "F: ";
$m2 = "T: ";
foreach( $mappings as $k => $v )
{
    if( $v === "." ) continue;
    if( $v !== "?" )
    {
        $m .= $k;
        $m2 .= $v;
    }
}

echo "\n$m\n$m2\n\n";

echo strtr( $cont, $mappings );
Profile picture
斟酌 鵬兄
Thu Apr 07 2016 22:39:07 GMT+0000 (Coordinated Universal Time)
Last modified: Fri Apr 08 2016 11:25:41 GMT+0000 (Coordinated Universal Time)
Comments
No comments here.
Do you even comment?
website: 
Not a valid website
Invalid email format
Please enter your email
*Name: 
Please enter a name
Submit
抱歉,Google Recaptcha 服務被牆掉了,所以不能回覆了