{"raw_statement":[{"iden":"problem statement","content":"We have a bingo card with a $3\\times3$ grid. The square at the $i$\\-th row from the top and the $j$\\-th column from the left contains the number $A_{i, j}$.\nThe MC will choose $N$ numbers, $b_1, b_2, \\cdots, b_N$. If our bingo sheet contains some of those numbers, we will mark them on our sheet.\nDetermine whether we will have a bingo when the $N$ numbers are chosen, that is, the sheet will contain three marked numbers in a row, column, or diagonal."},{"iden":"constraints","content":"*   All values in input are integers.\n*   $1 \\leq A_{i, j} \\leq 100$\n*   $A_{i_1, j_1} \\neq A_{i_2, j_2} ((i_1, j_1) \\neq (i_2, j_2))$\n*   $1 \\leq N \\leq 10$\n*   $1 \\leq b_i \\leq 100$\n*   $b_i \\neq b_j (i \\neq j)$"},{"iden":"input","content":"Input is given from Standard Input in the following format:\n\n$A_{1, 1}$ $A_{1, 2}$ $A_{1, 3}$\n$A_{2, 1}$ $A_{2, 2}$ $A_{2, 3}$\n$A_{3, 1}$ $A_{3, 2}$ $A_{3, 3}$\n$N$\n$b_1$\n$\\vdots$\n$b_N$"},{"iden":"sample input 1","content":"84 97 66\n79 89 11\n61 59 7\n7\n89\n7\n87\n79\n24\n84\n30"},{"iden":"sample output 1","content":"Yes\n\nWe will mark $A_{1, 1}, A_{2, 1}, A_{2, 2}, A_{3, 3}$, and complete the diagonal from the top-left to the bottom-right."},{"iden":"sample input 2","content":"41 7 46\n26 89 2\n78 92 8\n5\n6\n45\n16\n57\n17"},{"iden":"sample output 2","content":"No\n\nWe will mark nothing."},{"iden":"sample input 3","content":"60 88 34\n92 41 43\n65 73 48\n10\n60\n43\n88\n11\n48\n73\n65\n41\n92\n34"},{"iden":"sample output 3","content":"Yes\n\nWe will mark all the squares."}],"translated_statement":null,"sample_group":[],"show_order":["default"],"formal_statement":null,"simple_statement":null,"has_page_source":true}