← Back to archive

Stdle #119 · comparisons · 2026-10-03

What does this Ruby snippet output?

A past puzzle — fully playable. 4 attempts, hints on wrong guesses.

result = case {status: 200, body: "ok"}
in {status: 200, body:}
"success: #{body}"
in {status: 404}
"not found"
end
puts result
Comparisons
4 attempts left

Answer & explanation