Going to tackle a few more regex challenges. These are classified as Double Cross
Double Cross #1 (Telekinesis)
Should likely be doing this one in capitals, but…
Certainly messy looking. But my css handled it all rather well. I am putting the bottom column regexes in the table footer. So did have to add CSS too handle the arrow colours and text formatting for that region.
[^a-ru-z] | ||||
[d-hj-m] | ||||
[a-gn-z]+ | [^a-di-s]+ | |||
[^f-km-z] | ||||
[a-ks-v] |
Solve the Puzzle
Looking at the two row regexes we know the first column can only belong to the character set [e-gt-z]
. That is [a-g]
minus [a-d]
and [n-z]
minus [i-s]
. Now looking at the first column it only allows [d-ej-l]
. Then the intersection of those two reduced regexes leaves us with e
.
Similarly for the 2nd column. The reduced row regex remains [e-gt-z]
. The column regex goes to ([^l-rw-z][s-t])
. Their intersection gives us t
.
[^a-ru-z] | ||||
[d-hj-m] | ||||
[a-gn-z]+ | e | t | [^a-di-s]+ | |
[^f-km-z] | ||||
[a-ks-v] |
Given the puzzles title of Telekinesis, ET would seem to be a most reasonable answer.
Double Cross #2 (GMC Vandura)
Something a touch harder.
(tm|bf) | ||||
.a | ||||
[^mci]+ | ||||
(cat|a-t)+ | [^ki\sp]+ | |||
[ma\-\se]+ | (m|aps|ea)* | |||
[ai][e\s] | ||||
[a\-z]+ | ||||
[\st\-m]+ |
- \s : Any whitespace character (including \t, \n and a few others)
- [a\-d] : \- is a literal hyphen, so match “a”, “-”, or “d”
- [ab] : Match either “a” or “b
Solve the Puzzle
The leftmost regex on the first row says either cat
or a-t
one or more times. But first column regex says first character can not be a c
. So, a-t
it is. Left regex has no problem with that.
Then, given the top row, the upper third column regex tells us that column has to be tm
. Upper second column regex says 2nd character is literal a
. Then right regex for 2nd row says the first character must be e
to match the ea
in the alternation. And that’s that. When in trouble call on the:
(tm|bf) | ||||
.a | ||||
[^mci]+ | ||||
(cat|a-t)+ | a | - | t | [^ki\sp]+ |
[ma\-\se]+ | e | a | m | (m|aps|ea)* |
[ai][e\s] | ||||
[a\-z]+ | ||||
[\st\-m]+ |
Double Cross #3 (Bat Man)
Even messier.
[rush]+ | ||||
(p|et|o|tea)* | ||||
.*[gaf]* | ||||
[one]*[ska] | .*(o|s)* | |||
.*(re|er) | [^goa]* | |||
a+[tub]* | [stupa]+ | |||
(nf|fa|a|fn)+ | ||||
.*(a|e|i).* | ||||
[super]* |
Solution
Intersection for 1st row’s left regex and 1st column’s bottom regex say first 2 characters of first column are nf
. Neither of the 2nd rows regexes nor the column’s upper regex have a problem with that. The first row’s regex also says that a character must come from the 1st character class zero or more times and only once from the 2nd class. Given the second column’s top regex, our choices are et
or o
. But, 2nd column lower regex says 2nd character in column must be one of a, e, i
. et
would not satisfy these requirements. So, o
it is—which is acceptable to all four involved regexes. As for the row’s last character, only s
satisfies the 4 regexes involved.
That pretty much means that the 2nd and 3rd characters of the second column are et
. Which means the 2nd and 3rd characters of the 2nd row must be er
.
[rush]+ | ||||
(p|et|o|tea)* | ||||
.*[gaf]* | ||||
[one]*[ska] | n | o | s | .*(o|s)* |
.*(re|er) | f | e | r | [^goa]* |
a+[tub]* | t | [stupa]+ | ||
(nf|fa|a|fn)+ | ||||
.*(a|e|i).* | ||||
[super]* |
The first column of the 3rd row must be an a
, as the left regex calls for 1 or more as to start the row. And for the last character, the intersection of the 4 regexes only allows a u
.
[rush]+ | ||||
(p|et|o|tea)* | ||||
.*[gaf]* | ||||
[one]*[ska] | n | o | s | .*(o|s)* |
.*(re|er) | f | e | r | [^goa]* |
a+[tub]* | a | t | u | [stupa]+ |
(nf|fa|a|fn)+ | ||||
.*(a|e|i).* | ||||
[super]* |
According to Wikipedia:
Nosferatu was produced by Prana Film and is an unauthorized and unofficial adaptation of Bram Stoker’s 1897 novel Dracula.
Guess that fits with the title of Bat Man.
Done
I think I will continue with the rest of this set of crosswords in the next post.
Until then, if you find some time on your hands, give them a try. May you be a regular success.