{"problem":{"name":"F. Maze Design","description":{"content":"Alice has traveled back in time to Ancient Greece to meet one of her greatest idols, the famous inventor Daedulus. When Alice visits, Daedulus is analyzing a few maze passageways that he is considerin","description_type":"Markdown"},"platform":"Codeforces","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"CF10275F"},"statements":[{"statement_type":"Markdown","content":"Alice has traveled back in time to Ancient Greece to meet one of her greatest idols, the famous inventor Daedulus. When Alice visits, Daedulus is analyzing a few maze passageways that he is considering including in his latest creation, the soon-to-be famous Labyrinth. Alice jumps at the opportunity to help Daedulus and needs to build a solver that determines if a given maze passageway is solvable or not.\n\nA maze passageway consists of $3$ rows that each have $n$ positions. Each position can either be blocked, which means that Alice cannot move through that position, or open, which means that Alice can move through that position. To solve a particular maze passageway, a person can move in any of the cardinal directions, as long as they don't move into a blocked position or go out of bounds of the passageway. Alice can start in any of the $3$ rows at the first position and can successfully solve the maze if she can reach the final position at any of the $3$ rows.\n\nGiven a particular maze passageway that meets these criteria, you must output _Solvable!_ if Alice can solve the maze passageway and _Unsolvable!_ otherwise.\n\nThe first line will consist of a single integer $n$ ($2 <= n <= 10^4$), which gives the number of positions per row. The next $3$ lines consist of a string, $s$, with $n$ characters that are either _0_ or _1_, representing a row of the maze passage way. If $s_i =$ _0_, then the $i$th position in that row is open, and if $s_i =$ _1_, then the $i$th position in that row is blocked.\n\nOutput _Solvable!_ if the maze passageway is solvable and _Unsolvable!_ otherwise.\n\n## Input\n\nThe first line will consist of a single integer $n$ ($2 <= n <= 10^4$), which gives the number of positions per row. The next $3$ lines consist of a string, $s$, with $n$ characters that are either _0_ or _1_, representing a row of the maze passage way. If $s_i =$ _0_, then the $i$th position in that row is open, and if $s_i =$ _1_, then the $i$th position in that row is blocked.\n\n## Output\n\nOutput _Solvable!_ if the maze passageway is solvable and _Unsolvable!_ otherwise.\n\n[samples]","is_translate":false,"language":"English"},{"statement_type":"Markdown","content":"**Definitions**  \nLet $ n \\in \\mathbb{Z} $ with $ 2 \\leq n \\leq 10^4 $.  \nLet $ M = (r_1, r_2, r_3) $ be a $ 3 \\times n $ binary matrix, where $ r_i \\in \\{0,1\\}^n $ represents row $ i $, and $ r_{i,j} = 0 $ denotes an open cell, $ r_{i,j} = 1 $ denotes a blocked cell.\n\n**Constraints**  \n1. $ r_{i,j} \\in \\{0,1\\} $ for all $ i \\in \\{1,2,3\\} $, $ j \\in \\{1,\\dots,n\\} $.  \n2. Movement is allowed in cardinal directions (up, down, left, right) between adjacent open cells.  \n3. Start: any cell $ (i,1) $ with $ r_{i,1} = 0 $, $ i \\in \\{1,2,3\\} $.  \n4. Goal: reach any cell $ (i,n) $ with $ r_{i,n} = 0 $, $ i \\in \\{1,2,3\\} $.\n\n**Objective**  \nDetermine whether there exists a path from any starting cell $ (i,1) $ with $ r_{i,1} = 0 $ to any goal cell $ (j,n) $ with $ r_{j,n} = 0 $, using only moves between adjacent open cells.  \nOutput \"Solvable!\" if such a path exists; otherwise, output \"Unsolvable!\".","is_translate":false,"language":"Formal"}],"meta":{"iden":"CF10275F","tags":[],"sample_group":[],"created_at":"2026-03-03 11:00:39"}}