# Hiking Circuits

This is part 27 of the puzzle series Around the World in Many Days. Each part is solvable on its own.

Dear Puzzling,

How have you been? Today I have toured the coastal towns and islands of a major body of water. I have visited centuries-old ruins and statues and quiet little beaches, and seen monkeys and colourful parrots in the lush forests covering the mountain sides. Can you guess where I am?

– Drawing instructions –

–– Examples ––

... The problem ...

Gladys will return in Staying Connected.

First off, notice that

exactly eight letters (DGKORSUW) occur in first place, and exactly four (AIMN) in second place. That's already a bit suggestive. And, wait, that set of four looks familiar: they're the letters with length-2 Morse encodings. And, indeed, the first-place letters are exactly the letters with length-3 Morse encodings.

So

we are dealing with five-bit strings, which are operated on by our weird symbols, and at the end of each row we turn them into symbols by mapping each bit to one segment of the "5-segment LCD display".

What do those weird symbols do, exactly?

It looks, from the given examples, as if FIRE is exclusive-or, TOADSTOOL is bitwise-and, BLUE-THING is bitwise-or; RAINBOW is cyclic-shift-left, SPARK is bitwise-not, and TREE is cyclic-shift-right. For reasons I cannot guess, I initially thought that the cyclic shifts were within each letter rather than of the whole 5-bit value -- in the examples given, these all yield the same result. This gave me gibberish after the first couple of rows. Thankfully, user ttotherat spotted that shifting the whole thing makes everything work.

For instance, consider the first row.

Then we do FIRE (i.e., XOR) with UM = ..- -- = 001 11, getting 110 00.
Then we do TREE (i.e., right-shift), getting 011 00.
Then we do SPARK (i.e., not), getting 100 11.
Then we do TOADSTOOL (i.e., AND) with OA = --- .- = 111 01, getting 100 01.
Then we do BLUE-THING (i.e., OR) with RA = .-. .- = 010 01, getting 110 01.
Numbering our bits 1..5 from the left, that's bits 1,2,5.
That means the left, top, bottom segments.
That gives us a letter C.

Very nice so far. The next row

gives us a letter O,

also very reasonable. And with the boneheaded mistake mentioned above corrected, as user ttotherat has found, we get

COCIBOLCA, also known as Lake Nicaragua.

Credit where due: ttotherat spotted an idiotic thing I'd done and found that if you do the should-have-been-obvious less idiotic thing you get an answer that makes sense, rather than the gibberish I got. If you like my answer, please consider upvoting ttotherat's.

• rot13(Gur rknzcyrf frrz gb jbex sbe evtug-fuvsg be yrsg-fuvsg ba gur jubyr jbeq, abg whfg rnpu yrggre frcrengryl.) Jun 23 at 0:19
• D'oh! I wonder what it was that made me think it was the other thing -- it's not like it's simpler than the correct interpretation. Oh well. Jun 23 at 23:44
• @ttotherat That's correct! Instead of accepting your answer, though, I'd prefer to have that information incorporated in this answer since it already explains everything except that one small detail. (If that's fine by Gareth, that is.)
– Jafe
Jun 24 at 11:24
• I have no objection, but once again it's bedtime so I'll make the necessary edits tomorrow. Unless I forget, of course. I'm very good at forgetting things. Jun 25 at 0:29

Following Gareth's nearly complete answer, but with a slight modification:

Interpreting the rainbow and tree as full-word shifts, instead of letter-by-letter shifts

we find that you're visiting