package gcj.y2020.qual

private fun solve(possible: String = "POSSIBLE", impossible: String = "IMPOSSIBLE"): String {
//	for (n in 2..50) { solveDiagonal(n, 0, 0); solveDiagonal(n, 1, 1); solveDiagonal(n, 1, 2) }
	val (n, trace) = readInts()
	for (i in 1..n) for (j in 1..n) for (k in 1..n) {
		if ((i == j) xor (i == k) || (n - 2) * i + j + k != trace) continue
		val d0 = setOf(i, j).size - 1
		val d1 = setOf(i, j, k).size - 1
		val a = solveDiagonal(n, d0, d1) ?: continue
		val switch = IntArray(n) { -1 }
		switch[0] = i
		switch[d0] = j
		switch[d1] = k
		for (x in a.indices) if (switch[x] == -1) switch[x] = (1..n).first { it !in switch }
		return possible + "\n" + a.joinToString("\n") { row -> row.joinToString(" ") { switch[it].toString() } }
	}
	return impossible
}

private val memo = mutableMapOf<String, List<IntArray>?>()

private fun solveDiagonal(n: Int, d0: Int, d1: Int): List<IntArray>? {
	val code = "$n $d0 $d1"
	if (code in memo) return memo[code]
	val a = List(n) { IntArray(n) { -1 } }
	a.indices.forEach { i -> a[i][i] = 0 }
	a[0][0] = d0
	a[1][1] = d1
	memo[code] = if (d1 >= n) null else search(a)
	return memo[code]
}

private fun search(a: List<IntArray>, magic: Int = 3): List<IntArray>? {
	val n = a.size
	for (x in magic until n) for (y in magic until n) a[x][y] = (y - x + n) % n
	for (x in magic until n - magic) {
		a[0][x] = x - 1
		a[x][0] = n + 1 - x
		a[x][1] = n + 2 - x
		a[x][2] = n - x
	}
	val p = List(n) { LongArray(n) { -1L } }
	while (true) {
		for (i in a.indices) for (j in a.indices) {
			val v = a[i][j]
			if (v == -1) continue
			for (x in a.indices) {
				if (x != i) p[x][j] = p[x][j] and (1L shl v).inv()
				if (x != j) p[i][x] = p[i][x] and (1L shl v).inv()
				if (x != v) p[i][j] = p[i][j] and (1L shl x).inv()
			}
		}

		var improved = false
		for (x in a.indices) {
			for (y in a.indices) {
				var f = a.indices.filter { ((p[x][it] shr y) and 1) > 0 }
				if (f.isEmpty()) return null
				if (f.size == 1 && a[x][f.first()] == -1) {
					a[x][f.first()] = y
					improved = true
				}
				f = a.indices.filter { ((p[it][x] shr y) and 1) > 0 }
				if (f.isEmpty()) return null
				if (f.size == 1 && a[f.first()][x] == -1) {
					a[f.first()][x] = y
					improved = true
				}
				f = a.indices.filter { ((p[x][y] shr it) and 1) > 0 }
				if (f.isEmpty()) return null
				if (f.size == 1 && a[x][y] == -1) {
					a[x][y] = f.first()
					improved = true
				}
			}
		}
		if (!improved) break
	}

	for (i in a.indices) for (j in a.indices) {
		if (a[i][j] >= 0) continue
		for (v in a.indices) {
			if (((p[i][j] shr v) and 1) == 0L) continue
			val b = a.map { it.clone() }
			b[i][j] = v
			val res = search(b)
			if (res != null) return res
		}
		return null
	}
	return a
}

fun main() = repeat(readInt()) { println("Case #${it + 1}: ${solve()}") }

private fun readLn() = readLine()!!
private fun readInt() = readLn().toInt()
private fun readStrings() = readLn().split(" ")
private fun readInts() = readStrings().map { it.toInt() }

Compiled from "e.kt"
public final class gcj.y2020.qual.EKt {
  private static final java.util.Map<java.lang.String, java.util.List<int[]>> memo;

  private static final java.lang.String solve(java.lang.String, java.lang.String);
    Code:
       0: invokestatic  #10                 // Method readInts:()Ljava/util/List;
       3: astore_2
       4: aload_2
       5: iconst_0
       6: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      11: checkcast     #18                 // class java/lang/Number
      14: invokevirtual #22                 // Method java/lang/Number.intValue:()I
      17: istore_3
      18: aload_2
      19: iconst_1
      20: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      25: checkcast     #18                 // class java/lang/Number
      28: invokevirtual #22                 // Method java/lang/Number.intValue:()I
      31: istore        4
      33: iconst_1
      34: istore        5
      36: iload         5
      38: iload_3
      39: if_icmpgt     491
      42: iconst_1
      43: istore        6
      45: iload         6
      47: iload_3
      48: if_icmpgt     479
      51: iconst_1
      52: istore        7
      54: iload         7
      56: iload_3
      57: if_icmpgt     467
      60: iload         5
      62: iload         6
      64: if_icmpne     71
      67: iconst_1
      68: goto          72
      71: iconst_0
      72: iload         5
      74: iload         7
      76: if_icmpne     83
      79: iconst_1
      80: goto          84
      83: iconst_0
      84: ixor
      85: ifne          455
      88: iload_3
      89: iconst_2
      90: isub
      91: iload         5
      93: imul
      94: iload         6
      96: iadd
      97: iload         7
      99: iadd
     100: iload         4
     102: if_icmpeq     108
     105: goto          455
     108: iconst_2
     109: anewarray     #24                 // class java/lang/Integer
     112: astore        9
     114: aload         9
     116: iconst_0
     117: iload         5
     119: invokestatic  #28                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     122: aastore
     123: aload         9
     125: iconst_1
     126: iload         6
     128: invokestatic  #28                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     131: aastore
     132: aload         9
     134: invokestatic  #34                 // Method kotlin/collections/SetsKt.setOf:([Ljava/lang/Object;)Ljava/util/Set;
     137: invokeinterface #39,  1           // InterfaceMethod java/util/Set.size:()I
     142: iconst_1
     143: isub
     144: istore        8
     146: iconst_3
     147: anewarray     #24                 // class java/lang/Integer
     150: astore        10
     152: aload         10
     154: iconst_0
     155: iload         5
     157: invokestatic  #28                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     160: aastore
     161: aload         10
     163: iconst_1
     164: iload         6
     166: invokestatic  #28                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     169: aastore
     170: aload         10
     172: iconst_2
     173: iload         7
     175: invokestatic  #28                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     178: aastore
     179: aload         10
     181: invokestatic  #34                 // Method kotlin/collections/SetsKt.setOf:([Ljava/lang/Object;)Ljava/util/Set;
     184: invokeinterface #39,  1           // InterfaceMethod java/util/Set.size:()I
     189: iconst_1
     190: isub
     191: istore        9
     193: iload_3
     194: iload         8
     196: iload         9
     198: invokestatic  #43                 // Method solveDiagonal:(III)Ljava/util/List;
     201: dup
     202: ifnonnull     209
     205: pop
     206: goto          455
     209: astore        10
     211: iconst_0
     212: istore        12
     214: iload_3
     215: newarray       int
     217: astore        13
     219: iload         12
     221: iload_3
     222: if_icmpge     241
     225: iload         12
     227: istore        14
     229: aload         13
     231: iload         14
     233: iconst_m1
     234: iastore
     235: iinc          12, 1
     238: goto          219
     241: aload         13
     243: astore        11
     245: aload         11
     247: iconst_0
     248: iload         5
     250: iastore
     251: aload         11
     253: iload         8
     255: iload         6
     257: iastore
     258: aload         11
     260: iload         9
     262: iload         7
     264: iastore
     265: iconst_0
     266: istore        12
     268: aload         10
     270: checkcast     #45                 // class java/util/Collection
     273: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
     278: istore        13
     280: iload         12
     282: iload         13
     284: if_icmpge     405
     287: aload         11
     289: iload         12
     291: iaload
     292: iconst_m1
     293: if_icmpne     399
     296: aload         11
     298: iload         12
     300: new           #48                 // class kotlin/ranges/IntRange
     303: dup
     304: iconst_1
     305: iload_3
     306: invokespecial #52                 // Method kotlin/ranges/IntRange."<init>":(II)V
     309: checkcast     #54                 // class java/lang/Iterable
     312: astore        14
     314: istore        21
     316: astore        20
     318: iconst_0
     319: istore        15
     321: aload         14
     323: invokeinterface #58,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     328: astore        16
     330: aload         16
     332: invokeinterface #64,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     337: ifeq          380
     340: aload         16
     342: checkcast     #66                 // class kotlin/collections/IntIterator
     345: invokevirtual #69                 // Method kotlin/collections/IntIterator.nextInt:()I
     348: istore        17
     350: iload         17
     352: istore        18
     354: iconst_0
     355: istore        19
     357: aload         11
     359: iload         18
     361: invokestatic  #75                 // Method kotlin/collections/ArraysKt.contains:([II)Z
     364: ifne          371
     367: iconst_1
     368: goto          372
     371: iconst_0
     372: ifeq          330
     375: iload         17
     377: goto          390
     380: new           #77                 // class java/util/NoSuchElementException
     383: dup
     384: ldc           #79                 // String Collection contains no element matching the predicate.
     386: invokespecial #82                 // Method java/util/NoSuchElementException."<init>":(Ljava/lang/String;)V
     389: athrow
     390: istore        22
     392: aload         20
     394: iload         21
     396: iload         22
     398: iastore
     399: iinc          12, 1
     402: goto          280
     405: new           #84                 // class java/lang/StringBuilder
     408: dup
     409: invokespecial #87                 // Method java/lang/StringBuilder."<init>":()V
     412: aload_0
     413: invokevirtual #91                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     416: bipush        10
     418: invokevirtual #94                 // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder;
     421: aload         10
     423: checkcast     #54                 // class java/lang/Iterable
     426: ldc           #96                 // String \n
     428: checkcast     #98                 // class java/lang/CharSequence
     431: aconst_null
     432: aconst_null
     433: iconst_0
     434: aconst_null
     435: aload         11
     437: invokedynamic #118,  0            // InvokeDynamic #0:invoke:([I)Lkotlin/jvm/functions/Function1;
     442: bipush        30
     444: aconst_null
     445: invokestatic  #124                // Method kotlin/collections/CollectionsKt.joinToString$default:(Ljava/lang/Iterable;Ljava/lang/CharSequence;Ljava/lang/CharSequence;Ljava/lang/CharSequence;ILjava/lang/CharSequence;Lkotlin/jvm/functions/Function1;ILjava/lang/Object;)Ljava/lang/String;
     448: invokevirtual #91                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     451: invokevirtual #128                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
     454: areturn
     455: iload         7
     457: iload_3
     458: if_icmpeq     467
     461: iinc          7, 1
     464: goto          60
     467: iload         6
     469: iload_3
     470: if_icmpeq     479
     473: iinc          6, 1
     476: goto          51
     479: iload         5
     481: iload_3
     482: if_icmpeq     491
     485: iinc          5, 1
     488: goto          42
     491: aload_1
     492: areturn

  static java.lang.String solve$default(java.lang.String, java.lang.String, int, java.lang.Object);
    Code:
       0: iload_2
       1: iconst_1
       2: iand
       3: ifeq          9
       6: ldc           #159                // String POSSIBLE
       8: astore_0
       9: iload_2
      10: iconst_2
      11: iand
      12: ifeq          18
      15: ldc           #161                // String IMPOSSIBLE
      17: astore_1
      18: aload_0
      19: aload_1
      20: invokestatic  #163                // Method solve:(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
      23: areturn

  private static final java.util.List<int[]> solveDiagonal(int, int, int);
    Code:
       0: new           #84                 // class java/lang/StringBuilder
       3: dup
       4: invokespecial #87                 // Method java/lang/StringBuilder."<init>":()V
       7: iload_0
       8: invokevirtual #167                // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      11: bipush        32
      13: invokevirtual #94                 // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder;
      16: iload_1
      17: invokevirtual #167                // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      20: bipush        32
      22: invokevirtual #94                 // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder;
      25: iload_2
      26: invokevirtual #167                // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      29: invokevirtual #128                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
      32: astore_3
      33: getstatic     #171                // Field memo:Ljava/util/Map;
      36: aload_3
      37: invokeinterface #177,  2          // InterfaceMethod java/util/Map.containsKey:(Ljava/lang/Object;)Z
      42: ifeq          58
      45: getstatic     #171                // Field memo:Ljava/util/Map;
      48: aload_3
      49: invokeinterface #179,  2          // InterfaceMethod java/util/Map.get:(Ljava/lang/Object;)Ljava/lang/Object;
      54: checkcast     #12                 // class java/util/List
      57: areturn
      58: new           #181                // class java/util/ArrayList
      61: dup
      62: iload_0
      63: invokespecial #184                // Method java/util/ArrayList."<init>":(I)V
      66: astore        5
      68: iconst_0
      69: istore        6
      71: iload         6
      73: iload_0
      74: if_icmpge     137
      77: iload         6
      79: istore        7
      81: aload         5
      83: iload         7
      85: istore        8
      87: astore        13
      89: iconst_0
      90: istore        9
      92: iconst_0
      93: istore        10
      95: iload_0
      96: newarray       int
      98: astore        11
     100: iload         10
     102: iload_0
     103: if_icmpge     122
     106: iload         10
     108: istore        12
     110: aload         11
     112: iload         12
     114: iconst_m1
     115: iastore
     116: iinc          10, 1
     119: goto          100
     122: aload         11
     124: aload         13
     126: swap
     127: invokevirtual #187                // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
     130: pop
     131: iinc          6, 1
     134: goto          71
     137: aload         5
     139: checkcast     #12                 // class java/util/List
     142: astore        4
     144: aload         4
     146: checkcast     #45                 // class java/util/Collection
     149: invokestatic  #191                // Method kotlin/collections/CollectionsKt.getIndices:(Ljava/util/Collection;)Lkotlin/ranges/IntRange;
     152: checkcast     #54                 // class java/lang/Iterable
     155: astore        5
     157: iconst_0
     158: istore        6
     160: aload         5
     162: invokeinterface #58,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     167: astore        7
     169: aload         7
     171: invokeinterface #64,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     176: ifeq          216
     179: aload         7
     181: checkcast     #66                 // class kotlin/collections/IntIterator
     184: invokevirtual #69                 // Method kotlin/collections/IntIterator.nextInt:()I
     187: istore        8
     189: iload         8
     191: istore        9
     193: iconst_0
     194: istore        10
     196: aload         4
     198: iload         9
     200: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     205: checkcast     #155                // class "[I"
     208: iload         9
     210: iconst_0
     211: iastore
     212: nop
     213: goto          169
     216: nop
     217: aload         4
     219: iconst_0
     220: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     225: checkcast     #155                // class "[I"
     228: iconst_0
     229: iload_1
     230: iastore
     231: aload         4
     233: iconst_1
     234: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     239: checkcast     #155                // class "[I"
     242: iconst_1
     243: iload_2
     244: iastore
     245: getstatic     #171                // Field memo:Ljava/util/Map;
     248: aload_3
     249: iload_2
     250: iload_0
     251: if_icmplt     258
     254: aconst_null
     255: goto          266
     258: aload         4
     260: iconst_0
     261: iconst_2
     262: aconst_null
     263: invokestatic  #195                // Method search$default:(Ljava/util/List;IILjava/lang/Object;)Ljava/util/List;
     266: invokeinterface #199,  3          // InterfaceMethod java/util/Map.put:(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
     271: pop
     272: getstatic     #171                // Field memo:Ljava/util/Map;
     275: aload_3
     276: invokeinterface #179,  2          // InterfaceMethod java/util/Map.get:(Ljava/lang/Object;)Ljava/lang/Object;
     281: checkcast     #12                 // class java/util/List
     284: areturn

  private static final java.util.List<int[]> search(java.util.List<int[]>, int);
    Code:
       0: aload_0
       1: invokeinterface #208,  1          // InterfaceMethod java/util/List.size:()I
       6: istore_2
       7: iload_1
       8: istore_3
       9: iload_3
      10: iload_2
      11: if_icmpge     56
      14: iload_1
      15: istore        4
      17: iload         4
      19: iload_2
      20: if_icmpge     50
      23: aload_0
      24: iload_3
      25: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      30: checkcast     #155                // class "[I"
      33: iload         4
      35: iload         4
      37: iload_3
      38: isub
      39: iload_2
      40: iadd
      41: iload_2
      42: irem
      43: iastore
      44: iinc          4, 1
      47: goto          17
      50: iinc          3, 1
      53: goto          9
      56: iload_1
      57: istore_3
      58: iload_2
      59: iload_1
      60: isub
      61: istore        4
      63: iload_3
      64: iload         4
      66: if_icmpge     139
      69: aload_0
      70: iconst_0
      71: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      76: checkcast     #155                // class "[I"
      79: iload_3
      80: iload_3
      81: iconst_1
      82: isub
      83: iastore
      84: aload_0
      85: iload_3
      86: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      91: checkcast     #155                // class "[I"
      94: iconst_0
      95: iload_2
      96: iconst_1
      97: iadd
      98: iload_3
      99: isub
     100: iastore
     101: aload_0
     102: iload_3
     103: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     108: checkcast     #155                // class "[I"
     111: iconst_1
     112: iload_2
     113: iconst_2
     114: iadd
     115: iload_3
     116: isub
     117: iastore
     118: aload_0
     119: iload_3
     120: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     125: checkcast     #155                // class "[I"
     128: iconst_2
     129: iload_2
     130: iload_3
     131: isub
     132: iastore
     133: iinc          3, 1
     136: goto          63
     139: new           #181                // class java/util/ArrayList
     142: dup
     143: iload_2
     144: invokespecial #184                // Method java/util/ArrayList."<init>":(I)V
     147: astore        4
     149: iconst_0
     150: istore        5
     152: iload         5
     154: iload_2
     155: if_icmpge     220
     158: iload         5
     160: istore        6
     162: aload         4
     164: iload         6
     166: istore        7
     168: astore        20
     170: iconst_0
     171: istore        8
     173: iconst_0
     174: istore        9
     176: iload_2
     177: newarray       long
     179: astore        10
     181: iload         9
     183: iload_2
     184: if_icmpge     205
     187: iload         9
     189: istore        11
     191: aload         10
     193: iload         11
     195: ldc2_w        #209                // long -1l
     198: lastore
     199: iinc          9, 1
     202: goto          181
     205: aload         10
     207: aload         20
     209: swap
     210: invokevirtual #187                // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
     213: pop
     214: iinc          5, 1
     217: goto          152
     220: aload         4
     222: checkcast     #12                 // class java/util/List
     225: astore_3
     226: nop
     227: iconst_0
     228: istore        4
     230: aload_0
     231: checkcast     #45                 // class java/util/Collection
     234: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
     239: istore        5
     241: iload         4
     243: iload         5
     245: if_icmpge     462
     248: iconst_0
     249: istore        6
     251: aload_0
     252: checkcast     #45                 // class java/util/Collection
     255: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
     260: istore        7
     262: iload         6
     264: iload         7
     266: if_icmpge     456
     269: aload_0
     270: iload         4
     272: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     277: checkcast     #155                // class "[I"
     280: iload         6
     282: iaload
     283: istore        8
     285: iload         8
     287: iconst_m1
     288: if_icmpeq     450
     291: iconst_0
     292: istore        9
     294: aload_0
     295: checkcast     #45                 // class java/util/Collection
     298: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
     303: istore        10
     305: iload         9
     307: iload         10
     309: if_icmpge     450
     312: iload         9
     314: iload         4
     316: if_icmpeq     356
     319: aload_3
     320: iload         9
     322: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     327: checkcast     #212                // class "[J"
     330: iload         6
     332: aload_3
     333: iload         9
     335: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     340: checkcast     #212                // class "[J"
     343: iload         6
     345: laload
     346: lconst_1
     347: iload         8
     349: lshl
     350: ldc2_w        #209                // long -1l
     353: lxor
     354: land
     355: lastore
     356: iload         9
     358: iload         6
     360: if_icmpeq     400
     363: aload_3
     364: iload         4
     366: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     371: checkcast     #212                // class "[J"
     374: iload         9
     376: aload_3
     377: iload         4
     379: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     384: checkcast     #212                // class "[J"
     387: iload         9
     389: laload
     390: lconst_1
     391: iload         8
     393: lshl
     394: ldc2_w        #209                // long -1l
     397: lxor
     398: land
     399: lastore
     400: iload         9
     402: iload         8
     404: if_icmpeq     444
     407: aload_3
     408: iload         4
     410: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     415: checkcast     #212                // class "[J"
     418: iload         6
     420: aload_3
     421: iload         4
     423: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     428: checkcast     #212                // class "[J"
     431: iload         6
     433: laload
     434: lconst_1
     435: iload         9
     437: lshl
     438: ldc2_w        #209                // long -1l
     441: lxor
     442: land
     443: lastore
     444: iinc          9, 1
     447: goto          305
     450: iinc          6, 1
     453: goto          262
     456: iinc          4, 1
     459: goto          241
     462: iconst_0
     463: istore        4
     465: iconst_0
     466: istore        5
     468: aload_0
     469: checkcast     #45                 // class java/util/Collection
     472: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
     477: istore        6
     479: iload         5
     481: iload         6
     483: if_icmpge     1128
     486: iconst_0
     487: istore        7
     489: aload_0
     490: checkcast     #45                 // class java/util/Collection
     493: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
     498: istore        8
     500: iload         7
     502: iload         8
     504: if_icmpge     1122
     507: aload_0
     508: checkcast     #45                 // class java/util/Collection
     511: invokestatic  #191                // Method kotlin/collections/CollectionsKt.getIndices:(Ljava/util/Collection;)Lkotlin/ranges/IntRange;
     514: checkcast     #54                 // class java/lang/Iterable
     517: astore        10
     519: iconst_0
     520: istore        11
     522: aload         10
     524: astore        12
     526: new           #181                // class java/util/ArrayList
     529: dup
     530: invokespecial #213                // Method java/util/ArrayList."<init>":()V
     533: checkcast     #45                 // class java/util/Collection
     536: astore        13
     538: iconst_0
     539: istore        14
     541: aload         12
     543: invokeinterface #58,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     548: astore        15
     550: aload         15
     552: invokeinterface #64,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     557: ifeq          627
     560: aload         15
     562: invokeinterface #217,  1          // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     567: astore        16
     569: aload         16
     571: checkcast     #18                 // class java/lang/Number
     574: invokevirtual #22                 // Method java/lang/Number.intValue:()I
     577: istore        17
     579: iconst_0
     580: istore        18
     582: aload_3
     583: iload         5
     585: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     590: checkcast     #212                // class "[J"
     593: iload         17
     595: laload
     596: iload         7
     598: lshr
     599: lconst_1
     600: land
     601: lconst_0
     602: lcmp
     603: ifle          610
     606: iconst_1
     607: goto          611
     610: iconst_0
     611: ifeq          550
     614: aload         13
     616: aload         16
     618: invokeinterface #218,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     623: pop
     624: goto          550
     627: aload         13
     629: checkcast     #12                 // class java/util/List
     632: nop
     633: astore        9
     635: aload         9
     637: invokeinterface #221,  1          // InterfaceMethod java/util/List.isEmpty:()Z
     642: ifeq          647
     645: aconst_null
     646: areturn
     647: aload         9
     649: invokeinterface #208,  1          // InterfaceMethod java/util/List.size:()I
     654: iconst_1
     655: if_icmpne     713
     658: aload_0
     659: iload         5
     661: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     666: checkcast     #155                // class "[I"
     669: aload         9
     671: invokestatic  #225                // Method kotlin/collections/CollectionsKt.first:(Ljava/util/List;)Ljava/lang/Object;
     674: checkcast     #18                 // class java/lang/Number
     677: invokevirtual #22                 // Method java/lang/Number.intValue:()I
     680: iaload
     681: iconst_m1
     682: if_icmpne     713
     685: aload_0
     686: iload         5
     688: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     693: checkcast     #155                // class "[I"
     696: aload         9
     698: invokestatic  #225                // Method kotlin/collections/CollectionsKt.first:(Ljava/util/List;)Ljava/lang/Object;
     701: checkcast     #18                 // class java/lang/Number
     704: invokevirtual #22                 // Method java/lang/Number.intValue:()I
     707: iload         7
     709: iastore
     710: iconst_1
     711: istore        4
     713: aload_0
     714: checkcast     #45                 // class java/util/Collection
     717: invokestatic  #191                // Method kotlin/collections/CollectionsKt.getIndices:(Ljava/util/Collection;)Lkotlin/ranges/IntRange;
     720: checkcast     #54                 // class java/lang/Iterable
     723: astore        10
     725: iconst_0
     726: istore        11
     728: aload         10
     730: astore        12
     732: new           #181                // class java/util/ArrayList
     735: dup
     736: invokespecial #213                // Method java/util/ArrayList."<init>":()V
     739: checkcast     #45                 // class java/util/Collection
     742: astore        13
     744: iconst_0
     745: istore        14
     747: aload         12
     749: invokeinterface #58,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     754: astore        15
     756: aload         15
     758: invokeinterface #64,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     763: ifeq          833
     766: aload         15
     768: invokeinterface #217,  1          // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     773: astore        16
     775: aload         16
     777: checkcast     #18                 // class java/lang/Number
     780: invokevirtual #22                 // Method java/lang/Number.intValue:()I
     783: istore        17
     785: iconst_0
     786: istore        18
     788: aload_3
     789: iload         17
     791: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     796: checkcast     #212                // class "[J"
     799: iload         5
     801: laload
     802: iload         7
     804: lshr
     805: lconst_1
     806: land
     807: lconst_0
     808: lcmp
     809: ifle          816
     812: iconst_1
     813: goto          817
     816: iconst_0
     817: ifeq          756
     820: aload         13
     822: aload         16
     824: invokeinterface #218,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     829: pop
     830: goto          756
     833: aload         13
     835: checkcast     #12                 // class java/util/List
     838: nop
     839: astore        9
     841: aload         9
     843: invokeinterface #221,  1          // InterfaceMethod java/util/List.isEmpty:()Z
     848: ifeq          853
     851: aconst_null
     852: areturn
     853: aload         9
     855: invokeinterface #208,  1          // InterfaceMethod java/util/List.size:()I
     860: iconst_1
     861: if_icmpne     919
     864: aload_0
     865: aload         9
     867: invokestatic  #225                // Method kotlin/collections/CollectionsKt.first:(Ljava/util/List;)Ljava/lang/Object;
     870: checkcast     #18                 // class java/lang/Number
     873: invokevirtual #22                 // Method java/lang/Number.intValue:()I
     876: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     881: checkcast     #155                // class "[I"
     884: iload         5
     886: iaload
     887: iconst_m1
     888: if_icmpne     919
     891: aload_0
     892: aload         9
     894: invokestatic  #225                // Method kotlin/collections/CollectionsKt.first:(Ljava/util/List;)Ljava/lang/Object;
     897: checkcast     #18                 // class java/lang/Number
     900: invokevirtual #22                 // Method java/lang/Number.intValue:()I
     903: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     908: checkcast     #155                // class "[I"
     911: iload         5
     913: iload         7
     915: iastore
     916: iconst_1
     917: istore        4
     919: aload_0
     920: checkcast     #45                 // class java/util/Collection
     923: invokestatic  #191                // Method kotlin/collections/CollectionsKt.getIndices:(Ljava/util/Collection;)Lkotlin/ranges/IntRange;
     926: checkcast     #54                 // class java/lang/Iterable
     929: astore        10
     931: iconst_0
     932: istore        11
     934: aload         10
     936: astore        12
     938: new           #181                // class java/util/ArrayList
     941: dup
     942: invokespecial #213                // Method java/util/ArrayList."<init>":()V
     945: checkcast     #45                 // class java/util/Collection
     948: astore        13
     950: iconst_0
     951: istore        14
     953: aload         12
     955: invokeinterface #58,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     960: astore        15
     962: aload         15
     964: invokeinterface #64,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     969: ifeq          1039
     972: aload         15
     974: invokeinterface #217,  1          // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     979: astore        16
     981: aload         16
     983: checkcast     #18                 // class java/lang/Number
     986: invokevirtual #22                 // Method java/lang/Number.intValue:()I
     989: istore        17
     991: iconst_0
     992: istore        18
     994: aload_3
     995: iload         5
     997: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
    1002: checkcast     #212                // class "[J"
    1005: iload         7
    1007: laload
    1008: iload         17
    1010: lshr
    1011: lconst_1
    1012: land
    1013: lconst_0
    1014: lcmp
    1015: ifle          1022
    1018: iconst_1
    1019: goto          1023
    1022: iconst_0
    1023: ifeq          962
    1026: aload         13
    1028: aload         16
    1030: invokeinterface #218,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
    1035: pop
    1036: goto          962
    1039: aload         13
    1041: checkcast     #12                 // class java/util/List
    1044: nop
    1045: astore        9
    1047: aload         9
    1049: invokeinterface #221,  1          // InterfaceMethod java/util/List.isEmpty:()Z
    1054: ifeq          1059
    1057: aconst_null
    1058: areturn
    1059: aload         9
    1061: invokeinterface #208,  1          // InterfaceMethod java/util/List.size:()I
    1066: iconst_1
    1067: if_icmpne     1116
    1070: aload_0
    1071: iload         5
    1073: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
    1078: checkcast     #155                // class "[I"
    1081: iload         7
    1083: iaload
    1084: iconst_m1
    1085: if_icmpne     1116
    1088: aload_0
    1089: iload         5
    1091: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
    1096: checkcast     #155                // class "[I"
    1099: iload         7
    1101: aload         9
    1103: invokestatic  #225                // Method kotlin/collections/CollectionsKt.first:(Ljava/util/List;)Ljava/lang/Object;
    1106: checkcast     #18                 // class java/lang/Number
    1109: invokevirtual #22                 // Method java/lang/Number.intValue:()I
    1112: iastore
    1113: iconst_1
    1114: istore        4
    1116: iinc          7, 1
    1119: goto          500
    1122: iinc          5, 1
    1125: goto          479
    1128: iload         4
    1130: ifne          226
    1133: goto          1136
    1136: iconst_0
    1137: istore        4
    1139: aload_0
    1140: checkcast     #45                 // class java/util/Collection
    1143: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
    1148: istore        5
    1150: iload         4
    1152: iload         5
    1154: if_icmpge     1400
    1157: iconst_0
    1158: istore        6
    1160: aload_0
    1161: checkcast     #45                 // class java/util/Collection
    1164: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
    1169: istore        7
    1171: iload         6
    1173: iload         7
    1175: if_icmpge     1394
    1178: aload_0
    1179: iload         4
    1181: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
    1186: checkcast     #155                // class "[I"
    1189: iload         6
    1191: iaload
    1192: ifge          1388
    1195: iconst_0
    1196: istore        8
    1198: aload_0
    1199: checkcast     #45                 // class java/util/Collection
    1202: invokeinterface #46,  1           // InterfaceMethod java/util/Collection.size:()I
    1207: istore        9
    1209: iload         8
    1211: iload         9
    1213: if_icmpge     1386
    1216: aload_3
    1217: iload         4
    1219: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
    1224: checkcast     #212                // class "[J"
    1227: iload         6
    1229: laload
    1230: iload         8
    1232: lshr
    1233: lconst_1
    1234: land
    1235: lconst_0
    1236: lcmp
    1237: ifeq          1380
    1240: aload_0
    1241: checkcast     #54                 // class java/lang/Iterable
    1244: astore        11
    1246: iconst_0
    1247: istore        12
    1249: aload         11
    1251: astore        13
    1253: new           #181                // class java/util/ArrayList
    1256: dup
    1257: aload         11
    1259: bipush        10
    1261: invokestatic  #229                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
    1264: invokespecial #184                // Method java/util/ArrayList."<init>":(I)V
    1267: checkcast     #45                 // class java/util/Collection
    1270: astore        14
    1272: iconst_0
    1273: istore        15
    1275: aload         13
    1277: invokeinterface #58,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
    1282: astore        16
    1284: aload         16
    1286: invokeinterface #64,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
    1291: ifeq          1337
    1294: aload         16
    1296: invokeinterface #217,  1          // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
    1301: astore        17
    1303: aload         14
    1305: aload         17
    1307: checkcast     #155                // class "[I"
    1310: astore        18
    1312: astore        20
    1314: iconst_0
    1315: istore        19
    1317: aload         18
    1319: invokevirtual #232                // Method java/lang/Object.clone:()Ljava/lang/Object;
    1322: checkcast     #155                // class "[I"
    1325: aload         20
    1327: swap
    1328: invokeinterface #218,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
    1333: pop
    1334: goto          1284
    1337: aload         14
    1339: checkcast     #12                 // class java/util/List
    1342: nop
    1343: astore        10
    1345: aload         10
    1347: iload         4
    1349: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
    1354: checkcast     #155                // class "[I"
    1357: iload         6
    1359: iload         8
    1361: iastore
    1362: aload         10
    1364: iconst_0
    1365: iconst_2
    1366: aconst_null
    1367: invokestatic  #195                // Method search$default:(Ljava/util/List;IILjava/lang/Object;)Ljava/util/List;
    1370: astore        11
    1372: aload         11
    1374: ifnull        1380
    1377: aload         11
    1379: areturn
    1380: iinc          8, 1
    1383: goto          1209
    1386: aconst_null
    1387: areturn
    1388: iinc          6, 1
    1391: goto          1171
    1394: iinc          4, 1
    1397: goto          1150
    1400: aload_0
    1401: areturn

  static java.util.List search$default(java.util.List, int, int, java.lang.Object);
    Code:
       0: iload_2
       1: iconst_2
       2: iand
       3: ifeq          8
       6: iconst_3
       7: istore_1
       8: aload_0
       9: iload_1
      10: invokestatic  #261                // Method search:(Ljava/util/List;I)Ljava/util/List;
      13: areturn

  public static final void main();
    Code:
       0: invokestatic  #265                // Method readInt:()I
       3: istore_0
       4: iconst_0
       5: istore_1
       6: iload_1
       7: iload_0
       8: if_icmpge     67
      11: iload_1
      12: istore_2
      13: iconst_0
      14: istore_3
      15: new           #84                 // class java/lang/StringBuilder
      18: dup
      19: invokespecial #87                 // Method java/lang/StringBuilder."<init>":()V
      22: ldc_w         #267                // String Case #
      25: invokevirtual #91                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      28: iload_2
      29: iconst_1
      30: iadd
      31: invokevirtual #167                // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      34: ldc_w         #269                // String :
      37: invokevirtual #91                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      40: aconst_null
      41: aconst_null
      42: iconst_3
      43: aconst_null
      44: invokestatic  #271                // Method solve$default:(Ljava/lang/String;Ljava/lang/String;ILjava/lang/Object;)Ljava/lang/String;
      47: invokevirtual #91                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      50: invokevirtual #128                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
      53: getstatic     #277                // Field java/lang/System.out:Ljava/io/PrintStream;
      56: swap
      57: invokevirtual #283                // Method java/io/PrintStream.println:(Ljava/lang/Object;)V
      60: nop
      61: iinc          1, 1
      64: goto          6
      67: return

  private static final java.lang.String readLn();
    Code:
       0: invokestatic  #290                // Method kotlin/io/ConsoleKt.readLine:()Ljava/lang/String;
       3: dup
       4: invokestatic  #295                // Method kotlin/jvm/internal/Intrinsics.checkNotNull:(Ljava/lang/Object;)V
       7: areturn

  private static final int readInt();
    Code:
       0: invokestatic  #297                // Method readLn:()Ljava/lang/String;
       3: invokestatic  #301                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
       6: ireturn

  private static final java.util.List<java.lang.String> readStrings();
    Code:
       0: invokestatic  #297                // Method readLn:()Ljava/lang/String;
       3: checkcast     #98                 // class java/lang/CharSequence
       6: iconst_1
       7: anewarray     #152                // class java/lang/String
      10: astore_0
      11: aload_0
      12: iconst_0
      13: ldc_w         #305                // String
      16: aastore
      17: aload_0
      18: iconst_0
      19: iconst_0
      20: bipush        6
      22: aconst_null
      23: invokestatic  #311                // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[Ljava/lang/String;ZIILjava/lang/Object;)Ljava/util/List;
      26: areturn

  private static final java.util.List<java.lang.Integer> readInts();
    Code:
       0: invokestatic  #314                // Method readStrings:()Ljava/util/List;
       3: checkcast     #54                 // class java/lang/Iterable
       6: astore_0
       7: iconst_0
       8: istore_1
       9: aload_0
      10: astore_2
      11: new           #181                // class java/util/ArrayList
      14: dup
      15: aload_0
      16: bipush        10
      18: invokestatic  #229                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      21: invokespecial #184                // Method java/util/ArrayList."<init>":(I)V
      24: checkcast     #45                 // class java/util/Collection
      27: astore_3
      28: iconst_0
      29: istore        4
      31: aload_2
      32: invokeinterface #58,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      37: astore        5
      39: aload         5
      41: invokeinterface #64,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      46: ifeq          92
      49: aload         5
      51: invokeinterface #217,  1          // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      56: astore        6
      58: aload_3
      59: aload         6
      61: checkcast     #152                // class java/lang/String
      64: astore        7
      66: astore        9
      68: iconst_0
      69: istore        8
      71: aload         7
      73: invokestatic  #301                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
      76: nop
      77: invokestatic  #28                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
      80: aload         9
      82: swap
      83: invokeinterface #218,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
      88: pop
      89: goto          39
      92: aload_3
      93: checkcast     #12                 // class java/util/List
      96: nop
      97: areturn

  public static void main(java.lang.String[]);
    Code:
       0: invokestatic  #318                // Method main:()V
       3: return

  private static final java.lang.CharSequence solve$lambda$2$lambda$1(int[], int);
    Code:
       0: aload_0
       1: iload_1
       2: iaload
       3: invokestatic  #325                // Method java/lang/String.valueOf:(I)Ljava/lang/String;
       6: checkcast     #98                 // class java/lang/CharSequence
       9: areturn

  private static final java.lang.CharSequence solve$lambda$2(int[], int[]);
    Code:
       0: aload_1
       1: ldc_w         #328                // String row
       4: invokestatic  #332                // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       7: aload_1
       8: ldc_w         #305                // String
      11: checkcast     #98                 // class java/lang/CharSequence
      14: aconst_null
      15: aconst_null
      16: iconst_0
      17: aconst_null
      18: aload_0
      19: invokedynamic #338,  0            // InvokeDynamic #1:invoke:([I)Lkotlin/jvm/functions/Function1;
      24: bipush        30
      26: aconst_null
      27: invokestatic  #341                // Method kotlin/collections/ArraysKt.joinToString$default:([ILjava/lang/CharSequence;Ljava/lang/CharSequence;Ljava/lang/CharSequence;ILjava/lang/CharSequence;Lkotlin/jvm/functions/Function1;ILjava/lang/Object;)Ljava/lang/String;
      30: checkcast     #98                 // class java/lang/CharSequence
      33: areturn

  static {};
    Code:
       0: new           #344                // class java/util/LinkedHashMap
       3: dup
       4: invokespecial #345                // Method java/util/LinkedHashMap."<init>":()V
       7: checkcast     #173                // class java/util/Map
      10: putstatic     #171                // Field memo:Ljava/util/Map;
      13: return
}


package gcj.y2020.qual

private fun solve(n: Int, period: Int = 10) {
	val a = IntArray(n)
	var iter = 0
	fun ask(index: Int): Int {
		iter++
		println(index + 1)
		return readInt()
	}
	val first = IntArray(2) { -1 }
	val negated = IntArray(2) { -1 }
	fun fetchNegated(d: Int) {
		negated[d] = if (first[d] == -1) 0 else ask(first[d]) xor a[first[d]]
	}
	for (i in 0 until n / 2) {
		val j = n - 1 - i
		a[i] = ask(i); a[j] = ask(j)
		val d = a[i] xor a[j]
		if (first[d] == -1) {
			first[d] = i
			negated[d] = 0
		}
		if (negated[d] == -1) fetchNegated(d)
		a[i] = a[i] xor negated[d]; a[j] = a[j] xor negated[d]
		val needed = if (-1 in negated) 3 else 2
		if (iter + needed > period) {
			while (iter < period) ask(0)
			iter = 0
			negated.fill(-1)
		}
	}
	repeat(2) { fetchNegated(it) }
	val flipped = negated[0] xor negated[1]
	val ans = List(n) { a[if (flipped == 0) it else (n - 1 - it)] xor negated[0] }
	println(ans.joinToString(""))
}

fun main() {
	val (tests, n) = readInts()
	repeat(tests) {
		solve(n)
		assert(readLn() == "Y")
	}
}

private fun readLn() = readLine()!!
private fun readInt() = readLn().toInt()
private fun readStrings() = readLn().split(" ")
private fun readInts() = readStrings().map { it.toInt() }

Compiled from "d.kt"
public final class gcj.y2020.qual.DKt {
  private static final void solve(int, int);
    Code:
       0: iload_0
       1: newarray       int
       3: astore_2
       4: new           #8                  // class kotlin/jvm/internal/Ref$IntRef
       7: dup
       8: invokespecial #12                 // Method kotlin/jvm/internal/Ref$IntRef."<init>":()V
      11: astore_3
      12: iconst_0
      13: istore        5
      15: iconst_2
      16: newarray       int
      18: astore        6
      20: iload         5
      22: iconst_2
      23: if_icmpge     42
      26: iload         5
      28: istore        7
      30: aload         6
      32: iload         7
      34: iconst_m1
      35: iastore
      36: iinc          5, 1
      39: goto          20
      42: aload         6
      44: astore        4
      46: iconst_0
      47: istore        6
      49: iconst_2
      50: newarray       int
      52: astore        7
      54: iload         6
      56: iconst_2
      57: if_icmpge     76
      60: iload         6
      62: istore        8
      64: aload         7
      66: iload         8
      68: iconst_m1
      69: iastore
      70: iinc          6, 1
      73: goto          54
      76: aload         7
      78: astore        5
      80: iconst_0
      81: istore        6
      83: iload_0
      84: iconst_2
      85: idiv
      86: istore        7
      88: iload         6
      90: iload         7
      92: if_icmpge     270
      95: iload_0
      96: iconst_1
      97: isub
      98: iload         6
     100: isub
     101: istore        8
     103: aload_2
     104: iload         6
     106: aload_3
     107: iload         6
     109: invokestatic  #16                 // Method solve$ask:(Lkotlin/jvm/internal/Ref$IntRef;I)I
     112: iastore
     113: aload_2
     114: iload         8
     116: aload_3
     117: iload         8
     119: invokestatic  #16                 // Method solve$ask:(Lkotlin/jvm/internal/Ref$IntRef;I)I
     122: iastore
     123: aload_2
     124: iload         6
     126: iaload
     127: aload_2
     128: iload         8
     130: iaload
     131: ixor
     132: istore        9
     134: aload         4
     136: iload         9
     138: iaload
     139: iconst_m1
     140: if_icmpne     156
     143: aload         4
     145: iload         9
     147: iload         6
     149: iastore
     150: aload         5
     152: iload         9
     154: iconst_0
     155: iastore
     156: aload         5
     158: iload         9
     160: iaload
     161: iconst_m1
     162: if_icmpne     176
     165: aload         5
     167: aload         4
     169: aload_2
     170: aload_3
     171: iload         9
     173: invokestatic  #20                 // Method solve$fetchNegated:([I[I[ILkotlin/jvm/internal/Ref$IntRef;I)V
     176: aload_2
     177: iload         6
     179: aload_2
     180: iload         6
     182: iaload
     183: aload         5
     185: iload         9
     187: iaload
     188: ixor
     189: iastore
     190: aload_2
     191: iload         8
     193: aload_2
     194: iload         8
     196: iaload
     197: aload         5
     199: iload         9
     201: iaload
     202: ixor
     203: iastore
     204: aload         5
     206: iconst_m1
     207: invokestatic  #26                 // Method kotlin/collections/ArraysKt.contains:([II)Z
     210: ifeq          217
     213: iconst_3
     214: goto          218
     217: iconst_2
     218: istore        10
     220: aload_3
     221: getfield      #30                 // Field kotlin/jvm/internal/Ref$IntRef.element:I
     224: iload         10
     226: iadd
     227: iload_1
     228: if_icmple     264
     231: aload_3
     232: getfield      #30                 // Field kotlin/jvm/internal/Ref$IntRef.element:I
     235: iload_1
     236: if_icmpge     248
     239: aload_3
     240: iconst_0
     241: invokestatic  #16                 // Method solve$ask:(Lkotlin/jvm/internal/Ref$IntRef;I)I
     244: pop
     245: goto          231
     248: aload_3
     249: iconst_0
     250: putfield      #30                 // Field kotlin/jvm/internal/Ref$IntRef.element:I
     253: aload         5
     255: iconst_m1
     256: iconst_0
     257: iconst_0
     258: bipush        6
     260: aconst_null
     261: invokestatic  #34                 // Method kotlin/collections/ArraysKt.fill$default:([IIIIILjava/lang/Object;)V
     264: iinc          6, 1
     267: goto          88
     270: iconst_2
     271: istore        6
     273: iconst_0
     274: istore        7
     276: iload         7
     278: iload         6
     280: if_icmpge     307
     283: iload         7
     285: istore        8
     287: iconst_0
     288: istore        9
     290: aload         5
     292: aload         4
     294: aload_2
     295: aload_3
     296: iload         8
     298: invokestatic  #20                 // Method solve$fetchNegated:([I[I[ILkotlin/jvm/internal/Ref$IntRef;I)V
     301: iinc          7, 1
     304: goto          276
     307: aload         5
     309: iconst_0
     310: iaload
     311: aload         5
     313: iconst_1
     314: iaload
     315: ixor
     316: istore        6
     318: new           #36                 // class java/util/ArrayList
     321: dup
     322: iload_0
     323: invokespecial #39                 // Method java/util/ArrayList."<init>":(I)V
     326: astore        8
     328: iconst_0
     329: istore        9
     331: iload         9
     333: iload_0
     334: if_icmpge     391
     337: iload         9
     339: istore        10
     341: aload         8
     343: iload         10
     345: istore        11
     347: astore        13
     349: iconst_0
     350: istore        12
     352: aload_2
     353: iload         6
     355: ifne          363
     358: iload         11
     360: goto          369
     363: iload_0
     364: iconst_1
     365: isub
     366: iload         11
     368: isub
     369: iaload
     370: aload         5
     372: iconst_0
     373: iaload
     374: ixor
     375: invokestatic  #45                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     378: aload         13
     380: swap
     381: invokevirtual #49                 // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
     384: pop
     385: iinc          9, 1
     388: goto          331
     391: aload         8
     393: checkcast     #51                 // class java/util/List
     396: astore        7
     398: aload         7
     400: checkcast     #53                 // class java/lang/Iterable
     403: ldc           #55                 // String
     405: checkcast     #57                 // class java/lang/CharSequence
     408: aconst_null
     409: aconst_null
     410: iconst_0
     411: aconst_null
     412: aconst_null
     413: bipush        62
     415: aconst_null
     416: invokestatic  #63                 // Method kotlin/collections/CollectionsKt.joinToString$default:(Ljava/lang/Iterable;Ljava/lang/CharSequence;Ljava/lang/CharSequence;Ljava/lang/CharSequence;ILjava/lang/CharSequence;Lkotlin/jvm/functions/Function1;ILjava/lang/Object;)Ljava/lang/String;
     419: getstatic     #69                 // Field java/lang/System.out:Ljava/io/PrintStream;
     422: swap
     423: invokevirtual #75                 // Method java/io/PrintStream.println:(Ljava/lang/Object;)V
     426: return

  static void solve$default(int, int, int, java.lang.Object);
    Code:
       0: iload_2
       1: iconst_2
       2: iand
       3: ifeq          9
       6: bipush        10
       8: istore_1
       9: iload_0
      10: iload_1
      11: invokestatic  #98                 // Method solve:(II)V
      14: return

  public static final void main();
    Code:
       0: invokestatic  #103                // Method readInts:()Ljava/util/List;
       3: astore_0
       4: aload_0
       5: iconst_0
       6: invokeinterface #107,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      11: checkcast     #109                // class java/lang/Number
      14: invokevirtual #113                // Method java/lang/Number.intValue:()I
      17: istore_1
      18: aload_0
      19: iconst_1
      20: invokeinterface #107,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      25: checkcast     #109                // class java/lang/Number
      28: invokevirtual #113                // Method java/lang/Number.intValue:()I
      31: istore_2
      32: iconst_0
      33: istore_3
      34: iload_3
      35: iload_1
      36: if_icmpge     94
      39: iload_3
      40: istore        4
      42: iconst_0
      43: istore        5
      45: iload_2
      46: iconst_0
      47: iconst_2
      48: aconst_null
      49: invokestatic  #115                // Method solve$default:(IIILjava/lang/Object;)V
      52: invokestatic  #119                // Method readLn:()Ljava/lang/String;
      55: ldc           #121                // String Y
      57: invokestatic  #127                // Method kotlin/jvm/internal/Intrinsics.areEqual:(Ljava/lang/Object;Ljava/lang/Object;)Z
      60: istore        6
      62: getstatic     #133                // Field kotlin/_Assertions.ENABLED:Z
      65: ifeq          87
      68: iload         6
      70: ifne          87
      73: ldc           #135                // String Assertion failed
      75: astore        7
      77: new           #137                // class java/lang/AssertionError
      80: dup
      81: aload         7
      83: invokespecial #139                // Method java/lang/AssertionError."<init>":(Ljava/lang/Object;)V
      86: athrow
      87: nop
      88: iinc          3, 1
      91: goto          34
      94: return

  private static final java.lang.String readLn();
    Code:
       0: invokestatic  #146                // Method kotlin/io/ConsoleKt.readLine:()Ljava/lang/String;
       3: dup
       4: invokestatic  #149                // Method kotlin/jvm/internal/Intrinsics.checkNotNull:(Ljava/lang/Object;)V
       7: areturn

  private static final int readInt();
    Code:
       0: invokestatic  #119                // Method readLn:()Ljava/lang/String;
       3: invokestatic  #154                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
       6: ireturn

  private static final java.util.List<java.lang.String> readStrings();
    Code:
       0: invokestatic  #119                // Method readLn:()Ljava/lang/String;
       3: checkcast     #57                 // class java/lang/CharSequence
       6: iconst_1
       7: anewarray     #158                // class java/lang/String
      10: astore_0
      11: aload_0
      12: iconst_0
      13: ldc           #160                // String
      15: aastore
      16: aload_0
      17: iconst_0
      18: iconst_0
      19: bipush        6
      21: aconst_null
      22: invokestatic  #166                // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[Ljava/lang/String;ZIILjava/lang/Object;)Ljava/util/List;
      25: areturn

  private static final java.util.List<java.lang.Integer> readInts();
    Code:
       0: invokestatic  #169                // Method readStrings:()Ljava/util/List;
       3: checkcast     #53                 // class java/lang/Iterable
       6: astore_0
       7: iconst_0
       8: istore_1
       9: aload_0
      10: astore_2
      11: new           #36                 // class java/util/ArrayList
      14: dup
      15: aload_0
      16: bipush        10
      18: invokestatic  #173                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      21: invokespecial #39                 // Method java/util/ArrayList."<init>":(I)V
      24: checkcast     #175                // class java/util/Collection
      27: astore_3
      28: iconst_0
      29: istore        4
      31: aload_2
      32: invokeinterface #179,  1          // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      37: astore        5
      39: aload         5
      41: invokeinterface #185,  1          // InterfaceMethod java/util/Iterator.hasNext:()Z
      46: ifeq          92
      49: aload         5
      51: invokeinterface #189,  1          // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      56: astore        6
      58: aload_3
      59: aload         6
      61: checkcast     #158                // class java/lang/String
      64: astore        7
      66: astore        9
      68: iconst_0
      69: istore        8
      71: aload         7
      73: invokestatic  #154                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
      76: nop
      77: invokestatic  #45                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
      80: aload         9
      82: swap
      83: invokeinterface #190,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
      88: pop
      89: goto          39
      92: aload_3
      93: checkcast     #51                 // class java/util/List
      96: nop
      97: areturn

  public static void main(java.lang.String[]);
    Code:
       0: invokestatic  #204                // Method main:()V
       3: return

  private static final int solve$ask(kotlin.jvm.internal.Ref$IntRef, int);
    Code:
       0: aload_0
       1: getfield      #30                 // Field kotlin/jvm/internal/Ref$IntRef.element:I
       4: istore_2
       5: aload_0
       6: iload_2
       7: iconst_1
       8: iadd
       9: putfield      #30                 // Field kotlin/jvm/internal/Ref$IntRef.element:I
      12: iload_1
      13: iconst_1
      14: iadd
      15: istore_2
      16: getstatic     #69                 // Field java/lang/System.out:Ljava/io/PrintStream;
      19: iload_2
      20: invokevirtual #208                // Method java/io/PrintStream.println:(I)V
      23: invokestatic  #210                // Method readInt:()I
      26: ireturn

  private static final void solve$fetchNegated(int[], int[], int[], kotlin.jvm.internal.Ref$IntRef, int);
    Code:
       0: aload_0
       1: iload         4
       3: aload_1
       4: iload         4
       6: iaload
       7: iconst_m1
       8: if_icmpne     15
      11: iconst_0
      12: goto          30
      15: aload_3
      16: aload_1
      17: iload         4
      19: iaload
      20: invokestatic  #16                 // Method solve$ask:(Lkotlin/jvm/internal/Ref$IntRef;I)I
      23: aload_2
      24: aload_1
      25: iload         4
      27: iaload
      28: iaload
      29: ixor
      30: iastore
      31: return
}


package gcj.y2020.round3

private fun solve(): String {
	val (s, t) = readStrings()
	val way = generateSequence(t) { x -> prev(s, x) }.toList()
	return way[way.size / 2]
}

private fun prev(s: String, t: String): String? {
	if (s == t) return null
	val d = List(s.length + 1) { IntArray(t.length + 1) }
	for (i in s.indices) d[i + 1][0] = i + 1
	for (j in t.indices) d[0][j + 1] = j + 1
	for (i in s.indices) for (j in t.indices) {
		if (s[i] == t[j]) {
			d[i + 1][j + 1] = d[i][j]
			continue
		}
		d[i + 1][j + 1] = minOf(d[i][j], d[i + 1][j], d[i][j + 1]) + 1
	}
	var i = s.length
	var j = t.length
	val ansLast = StringBuilder()
	while (i > 0 && j > 0 && s[i - 1] == t[j - 1]) {
		ansLast.append(s[i - 1])
		i--; j--
	}
	val ans: String
	ans = if (i == 0) t.substring(1, j) else if (j == 0) s.substring(0, 1) else {
		if (d[i][j] == d[i - 1][j - 1] + 1) {
			t.substring(0, j - 1) + s[i - 1]
		} else if (d[i][j] == d[i - 1][j] + 1) {
			t.substring(0, j) + s[i - 1]
		} else {
			t.substring(0, j - 1)
		}
	}
	return ans + ansLast.toString().reversed()
}

fun main() = repeat(readInt()) { println("Case #${it + 1}: ${solve()}") }

private fun readLn() = readLine()!!
private fun readInt() = readLn().toInt()
private fun readStrings() = readLn().split(" ")

Compiled from "a.kt"
public final class gcj.y2020.round3.AKt {
  private static final java.lang.String solve();
    Code:
       0: invokestatic  #10                 // Method readStrings:()Ljava/util/List;
       3: astore_0
       4: aload_0
       5: iconst_0
       6: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      11: checkcast     #18                 // class java/lang/String
      14: astore_1
      15: aload_0
      16: iconst_1
      17: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      22: checkcast     #18                 // class java/lang/String
      25: astore_2
      26: aload_2
      27: aload_1
      28: invokedynamic #38,  0             // InvokeDynamic #0:invoke:(Ljava/lang/String;)Lkotlin/jvm/functions/Function1;
      33: invokestatic  #44                 // Method kotlin/sequences/SequencesKt.generateSequence:(Ljava/lang/Object;Lkotlin/jvm/functions/Function1;)Lkotlin/sequences/Sequence;
      36: invokestatic  #48                 // Method kotlin/sequences/SequencesKt.toList:(Lkotlin/sequences/Sequence;)Ljava/util/List;
      39: astore_3
      40: aload_3
      41: aload_3
      42: invokeinterface #52,  1           // InterfaceMethod java/util/List.size:()I
      47: iconst_2
      48: idiv
      49: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      54: checkcast     #18                 // class java/lang/String
      57: areturn

  private static final java.lang.String prev(java.lang.String, java.lang.String);
    Code:
       0: aload_0
       1: aload_1
       2: invokestatic  #64                 // Method kotlin/jvm/internal/Intrinsics.areEqual:(Ljava/lang/Object;Ljava/lang/Object;)Z
       5: ifeq          10
       8: aconst_null
       9: areturn
      10: aload_0
      11: invokevirtual #67                 // Method java/lang/String.length:()I
      14: iconst_1
      15: iadd
      16: istore_3
      17: new           #69                 // class java/util/ArrayList
      20: dup
      21: iload_3
      22: invokespecial #73                 // Method java/util/ArrayList."<init>":(I)V
      25: astore        4
      27: iconst_0
      28: istore        5
      30: iload         5
      32: iload_3
      33: if_icmpge     72
      36: iload         5
      38: istore        6
      40: aload         4
      42: iload         6
      44: istore        7
      46: astore        9
      48: iconst_0
      49: istore        8
      51: aload_1
      52: invokevirtual #67                 // Method java/lang/String.length:()I
      55: iconst_1
      56: iadd
      57: newarray       int
      59: aload         9
      61: swap
      62: invokevirtual #77                 // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
      65: pop
      66: iinc          5, 1
      69: goto          30
      72: aload         4
      74: checkcast     #12                 // class java/util/List
      77: astore_2
      78: iconst_0
      79: istore_3
      80: aload_0
      81: checkcast     #79                 // class java/lang/CharSequence
      84: invokeinterface #80,  1           // InterfaceMethod java/lang/CharSequence.length:()I
      89: istore        4
      91: iload_3
      92: iload         4
      94: if_icmpge     120
      97: aload_2
      98: iload_3
      99: iconst_1
     100: iadd
     101: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     106: checkcast     #82                 // class "[I"
     109: iconst_0
     110: iload_3
     111: iconst_1
     112: iadd
     113: iastore
     114: iinc          3, 1
     117: goto          91
     120: iconst_0
     121: istore_3
     122: aload_1
     123: checkcast     #79                 // class java/lang/CharSequence
     126: invokeinterface #80,  1           // InterfaceMethod java/lang/CharSequence.length:()I
     131: istore        4
     133: iload_3
     134: iload         4
     136: if_icmpge     162
     139: aload_2
     140: iconst_0
     141: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     146: checkcast     #82                 // class "[I"
     149: iload_3
     150: iconst_1
     151: iadd
     152: iload_3
     153: iconst_1
     154: iadd
     155: iastore
     156: iinc          3, 1
     159: goto          133
     162: iconst_0
     163: istore_3
     164: aload_0
     165: checkcast     #79                 // class java/lang/CharSequence
     168: invokeinterface #80,  1           // InterfaceMethod java/lang/CharSequence.length:()I
     173: istore        4
     175: iload_3
     176: iload         4
     178: if_icmpge     329
     181: iconst_0
     182: istore        5
     184: aload_1
     185: checkcast     #79                 // class java/lang/CharSequence
     188: invokeinterface #80,  1           // InterfaceMethod java/lang/CharSequence.length:()I
     193: istore        6
     195: iload         5
     197: iload         6
     199: if_icmpge     323
     202: aload_0
     203: iload_3
     204: invokevirtual #86                 // Method java/lang/String.charAt:(I)C
     207: aload_1
     208: iload         5
     210: invokevirtual #86                 // Method java/lang/String.charAt:(I)C
     213: if_icmpne     249
     216: aload_2
     217: iload_3
     218: iconst_1
     219: iadd
     220: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     225: checkcast     #82                 // class "[I"
     228: iload         5
     230: iconst_1
     231: iadd
     232: aload_2
     233: iload_3
     234: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     239: checkcast     #82                 // class "[I"
     242: iload         5
     244: iaload
     245: iastore
     246: goto          317
     249: aload_2
     250: iload_3
     251: iconst_1
     252: iadd
     253: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     258: checkcast     #82                 // class "[I"
     261: iload         5
     263: iconst_1
     264: iadd
     265: aload_2
     266: iload_3
     267: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     272: checkcast     #82                 // class "[I"
     275: iload         5
     277: iaload
     278: aload_2
     279: iload_3
     280: iconst_1
     281: iadd
     282: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     287: checkcast     #82                 // class "[I"
     290: iload         5
     292: iaload
     293: aload_2
     294: iload_3
     295: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     300: checkcast     #82                 // class "[I"
     303: iload         5
     305: iconst_1
     306: iadd
     307: iaload
     308: invokestatic  #92                 // Method java/lang/Math.min:(II)I
     311: invokestatic  #92                 // Method java/lang/Math.min:(II)I
     314: iconst_1
     315: iadd
     316: iastore
     317: iinc          5, 1
     320: goto          195
     323: iinc          3, 1
     326: goto          175
     329: aload_0
     330: invokevirtual #67                 // Method java/lang/String.length:()I
     333: istore_3
     334: aload_1
     335: invokevirtual #67                 // Method java/lang/String.length:()I
     338: istore        4
     340: new           #94                 // class java/lang/StringBuilder
     343: dup
     344: invokespecial #97                 // Method java/lang/StringBuilder."<init>":()V
     347: astore        5
     349: iload_3
     350: ifle          398
     353: iload         4
     355: ifle          398
     358: aload_0
     359: iload_3
     360: iconst_1
     361: isub
     362: invokevirtual #86                 // Method java/lang/String.charAt:(I)C
     365: aload_1
     366: iload         4
     368: iconst_1
     369: isub
     370: invokevirtual #86                 // Method java/lang/String.charAt:(I)C
     373: if_icmpne     398
     376: aload         5
     378: aload_0
     379: iload_3
     380: iconst_1
     381: isub
     382: invokevirtual #86                 // Method java/lang/String.charAt:(I)C
     385: invokevirtual #101                // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder;
     388: pop
     389: iinc          3, -1
     392: iinc          4, -1
     395: goto          349
     398: aconst_null
     399: astore        6
     401: iload_3
     402: ifne          421
     405: aload_1
     406: iconst_1
     407: iload         4
     409: invokevirtual #105                // Method java/lang/String.substring:(II)Ljava/lang/String;
     412: dup
     413: ldc           #107                // String substring(...)
     415: invokestatic  #111                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     418: goto          604
     421: iload         4
     423: ifne          441
     426: aload_0
     427: iconst_0
     428: iconst_1
     429: invokevirtual #105                // Method java/lang/String.substring:(II)Ljava/lang/String;
     432: dup
     433: ldc           #107                // String substring(...)
     435: invokestatic  #111                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     438: goto          604
     441: aload_2
     442: iload_3
     443: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     448: checkcast     #82                 // class "[I"
     451: iload         4
     453: iaload
     454: aload_2
     455: iload_3
     456: iconst_1
     457: isub
     458: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     463: checkcast     #82                 // class "[I"
     466: iload         4
     468: iconst_1
     469: isub
     470: iaload
     471: iconst_1
     472: iadd
     473: if_icmpne     517
     476: new           #94                 // class java/lang/StringBuilder
     479: dup
     480: invokespecial #97                 // Method java/lang/StringBuilder."<init>":()V
     483: aload_1
     484: iconst_0
     485: iload         4
     487: iconst_1
     488: isub
     489: invokevirtual #105                // Method java/lang/String.substring:(II)Ljava/lang/String;
     492: dup
     493: ldc           #107                // String substring(...)
     495: invokestatic  #111                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     498: invokevirtual #114                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     501: aload_0
     502: iload_3
     503: iconst_1
     504: isub
     505: invokevirtual #86                 // Method java/lang/String.charAt:(I)C
     508: invokevirtual #101                // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder;
     511: invokevirtual #117                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
     514: goto          604
     517: aload_2
     518: iload_3
     519: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     524: checkcast     #82                 // class "[I"
     527: iload         4
     529: iaload
     530: aload_2
     531: iload_3
     532: iconst_1
     533: isub
     534: invokeinterface #16,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     539: checkcast     #82                 // class "[I"
     542: iload         4
     544: iaload
     545: iconst_1
     546: iadd
     547: if_icmpne     589
     550: new           #94                 // class java/lang/StringBuilder
     553: dup
     554: invokespecial #97                 // Method java/lang/StringBuilder."<init>":()V
     557: aload_1
     558: iconst_0
     559: iload         4
     561: invokevirtual #105                // Method java/lang/String.substring:(II)Ljava/lang/String;
     564: dup
     565: ldc           #107                // String substring(...)
     567: invokestatic  #111                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     570: invokevirtual #114                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     573: aload_0
     574: iload_3
     575: iconst_1
     576: isub
     577: invokevirtual #86                 // Method java/lang/String.charAt:(I)C
     580: invokevirtual #101                // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder;
     583: invokevirtual #117                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
     586: goto          604
     589: aload_1
     590: iconst_0
     591: iload         4
     593: iconst_1
     594: isub
     595: invokevirtual #105                // Method java/lang/String.substring:(II)Ljava/lang/String;
     598: dup
     599: ldc           #107                // String substring(...)
     601: invokestatic  #111                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     604: astore        6
     606: new           #94                 // class java/lang/StringBuilder
     609: dup
     610: invokespecial #97                 // Method java/lang/StringBuilder."<init>":()V
     613: aload         6
     615: invokevirtual #114                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     618: aload         5
     620: invokevirtual #117                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
     623: dup
     624: ldc           #119                // String toString(...)
     626: invokestatic  #111                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     629: checkcast     #79                 // class java/lang/CharSequence
     632: invokestatic  #125                // Method kotlin/text/StringsKt.reversed:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
     635: invokevirtual #126                // Method java/lang/Object.toString:()Ljava/lang/String;
     638: invokevirtual #114                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     641: invokevirtual #117                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
     644: areturn

  public static final void main();
    Code:
       0: invokestatic  #139                // Method readInt:()I
       3: istore_0
       4: iconst_0
       5: istore_1
       6: iload_1
       7: iload_0
       8: if_icmpge     61
      11: iload_1
      12: istore_2
      13: iconst_0
      14: istore_3
      15: new           #94                 // class java/lang/StringBuilder
      18: dup
      19: invokespecial #97                 // Method java/lang/StringBuilder."<init>":()V
      22: ldc           #141                // String Case #
      24: invokevirtual #114                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      27: iload_2
      28: iconst_1
      29: iadd
      30: invokevirtual #144                // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      33: ldc           #146                // String :
      35: invokevirtual #114                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      38: invokestatic  #148                // Method solve:()Ljava/lang/String;
      41: invokevirtual #114                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      44: invokevirtual #117                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
      47: getstatic     #154                // Field java/lang/System.out:Ljava/io/PrintStream;
      50: swap
      51: invokevirtual #160                // Method java/io/PrintStream.println:(Ljava/lang/Object;)V
      54: nop
      55: iinc          1, 1
      58: goto          6
      61: return

  private static final java.lang.String readLn();
    Code:
       0: invokestatic  #167                // Method kotlin/io/ConsoleKt.readLine:()Ljava/lang/String;
       3: dup
       4: invokestatic  #170                // Method kotlin/jvm/internal/Intrinsics.checkNotNull:(Ljava/lang/Object;)V
       7: areturn

  private static final int readInt();
    Code:
       0: invokestatic  #172                // Method readLn:()Ljava/lang/String;
       3: invokestatic  #178                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
       6: ireturn

  private static final java.util.List<java.lang.String> readStrings();
    Code:
       0: invokestatic  #172                // Method readLn:()Ljava/lang/String;
       3: checkcast     #79                 // class java/lang/CharSequence
       6: iconst_1
       7: anewarray     #18                 // class java/lang/String
      10: astore_0
      11: aload_0
      12: iconst_0
      13: ldc           #181                // String
      15: aastore
      16: aload_0
      17: iconst_0
      18: iconst_0
      19: bipush        6
      21: aconst_null
      22: invokestatic  #185                // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[Ljava/lang/String;ZIILjava/lang/Object;)Ljava/util/List;
      25: areturn

  public static void main(java.lang.String[]);
    Code:
       0: invokestatic  #188                // Method main:()V
       3: return

  private static final java.lang.String solve$lambda$0(java.lang.String, java.lang.String);
    Code:
       0: aload_1
       1: ldc           #192                // String x
       3: invokestatic  #195                // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_0
       7: aload_1
       8: invokestatic  #197                // Method prev:(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
      11: areturn
}