package day8

import java.io.File

fun find_one_chars(input: List<List<Char>>): List<Char> {
    return input.find { it.size == 2 } ?: throw IllegalStateException("One not found")
}

fun find_four_chars(input: List<List<Char>>): List<Char> {
    return input.find { it.size == 4 } ?: throw IllegalStateException("Four not found")
}

fun find_seven_chars(input: List<List<Char>>): List<Char> {
    return input.find { it.size == 3 } ?: throw IllegalStateException("Seven not found")
}

fun find_eight_chars(input: List<List<Char>>): List<Char> {
    return input.find { it.size == 7 } ?: throw IllegalStateException("Seven not found")
}

fun find_nine_chars(input: List<List<Char>>, four: List<Char>): List<Char> {
    return input.filter { it.size == 6 }
        .find { it.containsAll(four) }
        ?: throw IllegalStateException("Nine not found")
}

fun find_zero_chars(input: List<List<Char>>, one: List<Char>, nine: List<Char>): List<Char> {
    return input
        .filter { it.size == 6 }
        .filter { it.containsAll(one) }
        .firstOrNull() { it != nine } ?: throw IllegalStateException("Zero not found")
}

fun find_six_chars(input: List<List<Char>>, nine: List<Char>, zero: List<Char>): List<Char> {
    return input
        .filter { it.size == 6 }
        .filter { it != nine }
        .firstOrNull() { it != zero } ?: throw IllegalStateException("Six not found")
}

fun find_five_chars(input: List<List<Char>>, six: List<Char>): List<Char> {
    return input
        .filter { it.size == 5 }
        .firstOrNull { six.containsAll(it) }?: throw IllegalStateException("Five not found")
}

fun find_three_chars(input: List<List<Char>>, seven: List<Char>): List<Char> {
    return input
        .filter { it.size == 5 }
        .firstOrNull { it.containsAll(seven) } ?: throw IllegalStateException("Three not found")
}

fun find_two_chars(input: List<List<Char>>, threeChars: List<Char>, fiveChars: List<Char>): List<Char> {
    return input
        .filter { it.size == 5 }
        .firstOrNull { it != threeChars && it != fiveChars }  ?: throw IllegalStateException("Three not found")
}

fun findMappings(input: List<List<Char>>): Map<List<Char>, Char> {
    val oneChars = find_one_chars(input).sorted()
    val fourChars = find_four_chars(input).sorted()
    val sevenChars = find_seven_chars(input).sorted()
    val eightChars = find_eight_chars(input).sorted()
    val nineChars = find_nine_chars(input, fourChars).sorted()
    val zeroChars = find_zero_chars(input, oneChars, nineChars).sorted()
    val sixChars = find_six_chars(input, nineChars, zeroChars).sorted()
    val threeChars = find_three_chars(input, sevenChars).sorted()
    val fiveChars = find_five_chars(input, sixChars).sorted()
    val twoChars = find_two_chars(input, threeChars, fiveChars).sorted()

    val map = mapOf(
        zeroChars.sorted() to '0',
        oneChars.sorted() to '1',
        twoChars.sorted() to '2',
        threeChars.sorted() to '3',
        fourChars.sorted() to '4',
        fiveChars.sorted() to '5',
        sixChars.sorted() to '6',
        sevenChars.sorted() to '7',
        eightChars.sorted() to '8',
        nineChars.sorted() to '9'
    )

    if (map.keys.size != 10) {
        map.values.sorted().forEach {
            println(it)
        }
        println("3 = " + map[threeChars])
        throw IllegalStateException("Map size is not 10")
    }

    return map
}

fun translate(input: List<List<Char>>, value: List<List<Char>>): List<Char> {
    val mappings = findMappings(input)

    return value.map { segments ->
        mappings[segments.sorted()] ?: '.'
    }
}

/*

 aa
b  c
b  c
 dd
e  f
e  f
 gg

[x]  0: 6  abcefg
[x]  1: 2  cf
[x]  2: 5  acdeg
[x]  3: 5  acdfg
[x]  4: 4  bcdf
[x]  5: 5  abdfg
[x]  6: 6  abdefg
[x]  7: 3  acf
[x]  8: 7  abcdefg
[x]  9: 6  abcdfg

[x]  1: 2  cf
[x]  7: 3  acf
[x]  4: 4  bcdf
[x]  2: 5  acdeg
[x]  3: 5  acdfg
[x]  5: 5  abdfg
[x]  6: 6  abdefg
[x]  9: 6  abcdfg
[x]  0: 6  abcefg
[x]  8: 7  abcdefg

  0:      1:      2:      3:      4:
 aaaa    ....    aaaa    aaaa    ....
b    c  .    c  .    c  .    c  b    c
b    c  .    c  .    c  .    c  b    c
 ....    ....    dddd    dddd    dddd
e    f  .    f  e    .  .    f  .    f
e    f  .    f  e    .  .    f  .    f
 gggg    ....    gggg    gggg    ....

  5:      6:      7:      8:      9:
 aaaa    aaaa    aaaa    aaaa    aaaa
b    .  b    .  .    c  b    c  b    c
b    .  b    .  .    c  b    c  b    c
 dddd    dddd    ....    dddd    dddd
.    f  e    f  .    f  e    f  .    f
.    f  e    f  .    f  e    f  .    f
 gggg    gggg    ....    gggg    gggg
 */

fun readInput(filename: String = "day8.txt"): List<Pair<List<List<Char>>, List<List<Char>>>> {
    return File(filename)
        .readLines()
        .map { line ->
            val (rawInput, rawValue) = line.split("|")
            Pair(
                rawInput.trim().split(" ").map { it.toCharArray().toList().sorted() },
                rawValue.trim().split(" ").map { it.toCharArray().toList().sorted() },
            )
        }
}

fun part1() {
    val inputs = readInput()

    val sum = inputs.map { (input, value) ->
        translate(input, value)
    }.sumOf {
        it.count { character -> character in listOf('1', '4', '7', '8') }
    }

    println("Digits: $sum")
}

fun part2() {
    val inputs = readInput()

    val sum = inputs.map { (input, value) ->
        translate(input, value)
    }.map {
        it.joinToString("").toInt()
    }.sum()

    print(sum)
}

fun part2_debug() {
    val inputs = readInput("day8_debug.txt")

    inputs.map { (input, value) ->
        translate(input, value)
    }.forEach { translation ->
        println(translation.joinToString(""))
    }
}

fun main() {
    part2()
}

Compiled from "Day8.kt"
public final class day8.Day8Kt {
  public static final java.util.List<java.lang.Character> find_one_chars(java.util.List<? extends java.util.List<java.lang.Character>>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_0
       7: checkcast     #18                 // class java/lang/Iterable
      10: astore_1
      11: aload_1
      12: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      17: astore_2
      18: aload_2
      19: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      24: ifeq          66
      27: aload_2
      28: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      33: astore_3
      34: aload_3
      35: checkcast     #34                 // class java/util/List
      38: astore        4
      40: iconst_0
      41: istore        5
      43: aload         4
      45: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      50: iconst_2
      51: if_icmpne     58
      54: iconst_1
      55: goto          59
      58: iconst_0
      59: ifeq          18
      62: aload_3
      63: goto          67
      66: aconst_null
      67: checkcast     #34                 // class java/util/List
      70: dup
      71: ifnonnull     85
      74: pop
      75: new           #40                 // class java/lang/IllegalStateException
      78: dup
      79: ldc           #42                 // String One not found
      81: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
      84: athrow
      85: areturn

  public static final java.util.List<java.lang.Character> find_four_chars(java.util.List<? extends java.util.List<java.lang.Character>>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_0
       7: checkcast     #18                 // class java/lang/Iterable
      10: astore_1
      11: aload_1
      12: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      17: astore_2
      18: aload_2
      19: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      24: ifeq          66
      27: aload_2
      28: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      33: astore_3
      34: aload_3
      35: checkcast     #34                 // class java/util/List
      38: astore        4
      40: iconst_0
      41: istore        5
      43: aload         4
      45: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      50: iconst_4
      51: if_icmpne     58
      54: iconst_1
      55: goto          59
      58: iconst_0
      59: ifeq          18
      62: aload_3
      63: goto          67
      66: aconst_null
      67: checkcast     #34                 // class java/util/List
      70: dup
      71: ifnonnull     85
      74: pop
      75: new           #40                 // class java/lang/IllegalStateException
      78: dup
      79: ldc           #53                 // String Four not found
      81: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
      84: athrow
      85: areturn

  public static final java.util.List<java.lang.Character> find_seven_chars(java.util.List<? extends java.util.List<java.lang.Character>>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_0
       7: checkcast     #18                 // class java/lang/Iterable
      10: astore_1
      11: aload_1
      12: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      17: astore_2
      18: aload_2
      19: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      24: ifeq          66
      27: aload_2
      28: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      33: astore_3
      34: aload_3
      35: checkcast     #34                 // class java/util/List
      38: astore        4
      40: iconst_0
      41: istore        5
      43: aload         4
      45: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      50: iconst_3
      51: if_icmpne     58
      54: iconst_1
      55: goto          59
      58: iconst_0
      59: ifeq          18
      62: aload_3
      63: goto          67
      66: aconst_null
      67: checkcast     #34                 // class java/util/List
      70: dup
      71: ifnonnull     85
      74: pop
      75: new           #40                 // class java/lang/IllegalStateException
      78: dup
      79: ldc           #57                 // String Seven not found
      81: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
      84: athrow
      85: areturn

  public static final java.util.List<java.lang.Character> find_eight_chars(java.util.List<? extends java.util.List<java.lang.Character>>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_0
       7: checkcast     #18                 // class java/lang/Iterable
      10: astore_1
      11: aload_1
      12: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      17: astore_2
      18: aload_2
      19: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      24: ifeq          67
      27: aload_2
      28: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      33: astore_3
      34: aload_3
      35: checkcast     #34                 // class java/util/List
      38: astore        4
      40: iconst_0
      41: istore        5
      43: aload         4
      45: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      50: bipush        7
      52: if_icmpne     59
      55: iconst_1
      56: goto          60
      59: iconst_0
      60: ifeq          18
      63: aload_3
      64: goto          68
      67: aconst_null
      68: checkcast     #34                 // class java/util/List
      71: dup
      72: ifnonnull     86
      75: pop
      76: new           #40                 // class java/lang/IllegalStateException
      79: dup
      80: ldc           #57                 // String Seven not found
      82: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
      85: athrow
      86: areturn

  public static final java.util.List<java.lang.Character> find_nine_chars(java.util.List<? extends java.util.List<java.lang.Character>>, java.util.List<java.lang.Character>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: ldc           #65                 // String four
       9: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      12: aload_0
      13: checkcast     #18                 // class java/lang/Iterable
      16: astore_2
      17: iconst_0
      18: istore_3
      19: aload_2
      20: astore        4
      22: new           #67                 // class java/util/ArrayList
      25: dup
      26: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
      29: checkcast     #72                 // class java/util/Collection
      32: astore        5
      34: iconst_0
      35: istore        6
      37: aload         4
      39: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      44: astore        7
      46: aload         7
      48: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      53: ifeq          108
      56: aload         7
      58: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      63: astore        8
      65: aload         8
      67: checkcast     #34                 // class java/util/List
      70: astore        9
      72: iconst_0
      73: istore        10
      75: aload         9
      77: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      82: bipush        6
      84: if_icmpne     91
      87: iconst_1
      88: goto          92
      91: iconst_0
      92: ifeq          46
      95: aload         5
      97: aload         8
      99: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     104: pop
     105: goto          46
     108: aload         5
     110: checkcast     #34                 // class java/util/List
     113: nop
     114: checkcast     #18                 // class java/lang/Iterable
     117: astore_3
     118: aload_3
     119: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     124: astore        4
     126: aload         4
     128: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     133: ifeq          174
     136: aload         4
     138: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     143: astore        5
     145: aload         5
     147: checkcast     #34                 // class java/util/List
     150: astore        6
     152: iconst_0
     153: istore        7
     155: aload         6
     157: aload_1
     158: checkcast     #72                 // class java/util/Collection
     161: invokeinterface #80,  2           // InterfaceMethod java/util/List.containsAll:(Ljava/util/Collection;)Z
     166: ifeq          126
     169: aload         5
     171: goto          175
     174: aconst_null
     175: checkcast     #34                 // class java/util/List
     178: dup
     179: ifnonnull     193
     182: pop
     183: new           #40                 // class java/lang/IllegalStateException
     186: dup
     187: ldc           #82                 // String Nine not found
     189: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
     192: athrow
     193: areturn

  public static final java.util.List<java.lang.Character> find_zero_chars(java.util.List<? extends java.util.List<java.lang.Character>>, java.util.List<java.lang.Character>, java.util.List<java.lang.Character>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: ldc           #98                 // String one
       9: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      12: aload_2
      13: ldc           #100                // String nine
      15: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      18: aload_0
      19: checkcast     #18                 // class java/lang/Iterable
      22: astore_3
      23: nop
      24: iconst_0
      25: istore        4
      27: aload_3
      28: astore        5
      30: new           #67                 // class java/util/ArrayList
      33: dup
      34: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
      37: checkcast     #72                 // class java/util/Collection
      40: astore        6
      42: iconst_0
      43: istore        7
      45: aload         5
      47: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      52: astore        8
      54: aload         8
      56: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      61: ifeq          116
      64: aload         8
      66: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      71: astore        9
      73: aload         9
      75: checkcast     #34                 // class java/util/List
      78: astore        10
      80: iconst_0
      81: istore        11
      83: aload         10
      85: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      90: bipush        6
      92: if_icmpne     99
      95: iconst_1
      96: goto          100
      99: iconst_0
     100: ifeq          54
     103: aload         6
     105: aload         9
     107: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     112: pop
     113: goto          54
     116: aload         6
     118: checkcast     #34                 // class java/util/List
     121: nop
     122: checkcast     #18                 // class java/lang/Iterable
     125: astore_3
     126: nop
     127: iconst_0
     128: istore        4
     130: aload_3
     131: astore        5
     133: new           #67                 // class java/util/ArrayList
     136: dup
     137: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
     140: checkcast     #72                 // class java/util/Collection
     143: astore        6
     145: iconst_0
     146: istore        7
     148: aload         5
     150: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     155: astore        8
     157: aload         8
     159: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     164: ifeq          213
     167: aload         8
     169: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     174: astore        9
     176: aload         9
     178: checkcast     #34                 // class java/util/List
     181: astore        10
     183: iconst_0
     184: istore        11
     186: aload         10
     188: aload_1
     189: checkcast     #72                 // class java/util/Collection
     192: invokeinterface #80,  2           // InterfaceMethod java/util/List.containsAll:(Ljava/util/Collection;)Z
     197: ifeq          157
     200: aload         6
     202: aload         9
     204: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     209: pop
     210: goto          157
     213: aload         6
     215: checkcast     #34                 // class java/util/List
     218: nop
     219: checkcast     #18                 // class java/lang/Iterable
     222: astore_3
     223: nop
     224: iconst_0
     225: istore        4
     227: aload_3
     228: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     233: astore        5
     235: aload         5
     237: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     242: ifeq          286
     245: aload         5
     247: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     252: astore        6
     254: aload         6
     256: checkcast     #34                 // class java/util/List
     259: astore        7
     261: iconst_0
     262: istore        8
     264: aload         7
     266: aload_2
     267: invokestatic  #104                // Method kotlin/jvm/internal/Intrinsics.areEqual:(Ljava/lang/Object;Ljava/lang/Object;)Z
     270: ifne          277
     273: iconst_1
     274: goto          278
     277: iconst_0
     278: ifeq          235
     281: aload         6
     283: goto          287
     286: aconst_null
     287: checkcast     #34                 // class java/util/List
     290: dup
     291: ifnonnull     305
     294: pop
     295: new           #40                 // class java/lang/IllegalStateException
     298: dup
     299: ldc           #106                // String Zero not found
     301: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
     304: athrow
     305: areturn

  public static final java.util.List<java.lang.Character> find_six_chars(java.util.List<? extends java.util.List<java.lang.Character>>, java.util.List<java.lang.Character>, java.util.List<java.lang.Character>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: ldc           #100                // String nine
       9: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      12: aload_2
      13: ldc           #115                // String zero
      15: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      18: aload_0
      19: checkcast     #18                 // class java/lang/Iterable
      22: astore_3
      23: nop
      24: iconst_0
      25: istore        4
      27: aload_3
      28: astore        5
      30: new           #67                 // class java/util/ArrayList
      33: dup
      34: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
      37: checkcast     #72                 // class java/util/Collection
      40: astore        6
      42: iconst_0
      43: istore        7
      45: aload         5
      47: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      52: astore        8
      54: aload         8
      56: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      61: ifeq          116
      64: aload         8
      66: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      71: astore        9
      73: aload         9
      75: checkcast     #34                 // class java/util/List
      78: astore        10
      80: iconst_0
      81: istore        11
      83: aload         10
      85: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      90: bipush        6
      92: if_icmpne     99
      95: iconst_1
      96: goto          100
      99: iconst_0
     100: ifeq          54
     103: aload         6
     105: aload         9
     107: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     112: pop
     113: goto          54
     116: aload         6
     118: checkcast     #34                 // class java/util/List
     121: nop
     122: checkcast     #18                 // class java/lang/Iterable
     125: astore_3
     126: nop
     127: iconst_0
     128: istore        4
     130: aload_3
     131: astore        5
     133: new           #67                 // class java/util/ArrayList
     136: dup
     137: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
     140: checkcast     #72                 // class java/util/Collection
     143: astore        6
     145: iconst_0
     146: istore        7
     148: aload         5
     150: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     155: astore        8
     157: aload         8
     159: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     164: ifeq          216
     167: aload         8
     169: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     174: astore        9
     176: aload         9
     178: checkcast     #34                 // class java/util/List
     181: astore        10
     183: iconst_0
     184: istore        11
     186: aload         10
     188: aload_1
     189: invokestatic  #104                // Method kotlin/jvm/internal/Intrinsics.areEqual:(Ljava/lang/Object;Ljava/lang/Object;)Z
     192: ifne          199
     195: iconst_1
     196: goto          200
     199: iconst_0
     200: ifeq          157
     203: aload         6
     205: aload         9
     207: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     212: pop
     213: goto          157
     216: aload         6
     218: checkcast     #34                 // class java/util/List
     221: nop
     222: checkcast     #18                 // class java/lang/Iterable
     225: astore_3
     226: nop
     227: iconst_0
     228: istore        4
     230: aload_3
     231: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     236: astore        5
     238: aload         5
     240: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     245: ifeq          289
     248: aload         5
     250: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     255: astore        6
     257: aload         6
     259: checkcast     #34                 // class java/util/List
     262: astore        7
     264: iconst_0
     265: istore        8
     267: aload         7
     269: aload_2
     270: invokestatic  #104                // Method kotlin/jvm/internal/Intrinsics.areEqual:(Ljava/lang/Object;Ljava/lang/Object;)Z
     273: ifne          280
     276: iconst_1
     277: goto          281
     280: iconst_0
     281: ifeq          238
     284: aload         6
     286: goto          290
     289: aconst_null
     290: checkcast     #34                 // class java/util/List
     293: dup
     294: ifnonnull     308
     297: pop
     298: new           #40                 // class java/lang/IllegalStateException
     301: dup
     302: ldc           #117                // String Six not found
     304: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
     307: athrow
     308: areturn

  public static final java.util.List<java.lang.Character> find_five_chars(java.util.List<? extends java.util.List<java.lang.Character>>, java.util.List<java.lang.Character>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: ldc           #123                // String six
       9: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      12: aload_0
      13: checkcast     #18                 // class java/lang/Iterable
      16: astore_2
      17: nop
      18: iconst_0
      19: istore_3
      20: aload_2
      21: astore        4
      23: new           #67                 // class java/util/ArrayList
      26: dup
      27: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
      30: checkcast     #72                 // class java/util/Collection
      33: astore        5
      35: iconst_0
      36: istore        6
      38: aload         4
      40: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      45: astore        7
      47: aload         7
      49: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      54: ifeq          108
      57: aload         7
      59: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      64: astore        8
      66: aload         8
      68: checkcast     #34                 // class java/util/List
      71: astore        9
      73: iconst_0
      74: istore        10
      76: aload         9
      78: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      83: iconst_5
      84: if_icmpne     91
      87: iconst_1
      88: goto          92
      91: iconst_0
      92: ifeq          47
      95: aload         5
      97: aload         8
      99: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     104: pop
     105: goto          47
     108: aload         5
     110: checkcast     #34                 // class java/util/List
     113: nop
     114: checkcast     #18                 // class java/lang/Iterable
     117: astore_2
     118: nop
     119: iconst_0
     120: istore_3
     121: aload_2
     122: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     127: astore        4
     129: aload         4
     131: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     136: ifeq          177
     139: aload         4
     141: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     146: astore        5
     148: aload         5
     150: checkcast     #34                 // class java/util/List
     153: astore        6
     155: iconst_0
     156: istore        7
     158: aload_1
     159: aload         6
     161: checkcast     #72                 // class java/util/Collection
     164: invokeinterface #80,  2           // InterfaceMethod java/util/List.containsAll:(Ljava/util/Collection;)Z
     169: ifeq          129
     172: aload         5
     174: goto          178
     177: aconst_null
     178: checkcast     #34                 // class java/util/List
     181: dup
     182: ifnonnull     196
     185: pop
     186: new           #40                 // class java/lang/IllegalStateException
     189: dup
     190: ldc           #125                // String Five not found
     192: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
     195: athrow
     196: areturn

  public static final java.util.List<java.lang.Character> find_three_chars(java.util.List<? extends java.util.List<java.lang.Character>>, java.util.List<java.lang.Character>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: ldc           #130                // String seven
       9: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      12: aload_0
      13: checkcast     #18                 // class java/lang/Iterable
      16: astore_2
      17: nop
      18: iconst_0
      19: istore_3
      20: aload_2
      21: astore        4
      23: new           #67                 // class java/util/ArrayList
      26: dup
      27: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
      30: checkcast     #72                 // class java/util/Collection
      33: astore        5
      35: iconst_0
      36: istore        6
      38: aload         4
      40: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      45: astore        7
      47: aload         7
      49: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      54: ifeq          108
      57: aload         7
      59: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      64: astore        8
      66: aload         8
      68: checkcast     #34                 // class java/util/List
      71: astore        9
      73: iconst_0
      74: istore        10
      76: aload         9
      78: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      83: iconst_5
      84: if_icmpne     91
      87: iconst_1
      88: goto          92
      91: iconst_0
      92: ifeq          47
      95: aload         5
      97: aload         8
      99: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     104: pop
     105: goto          47
     108: aload         5
     110: checkcast     #34                 // class java/util/List
     113: nop
     114: checkcast     #18                 // class java/lang/Iterable
     117: astore_2
     118: nop
     119: iconst_0
     120: istore_3
     121: aload_2
     122: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     127: astore        4
     129: aload         4
     131: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     136: ifeq          177
     139: aload         4
     141: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     146: astore        5
     148: aload         5
     150: checkcast     #34                 // class java/util/List
     153: astore        6
     155: iconst_0
     156: istore        7
     158: aload         6
     160: aload_1
     161: checkcast     #72                 // class java/util/Collection
     164: invokeinterface #80,  2           // InterfaceMethod java/util/List.containsAll:(Ljava/util/Collection;)Z
     169: ifeq          129
     172: aload         5
     174: goto          178
     177: aconst_null
     178: checkcast     #34                 // class java/util/List
     181: dup
     182: ifnonnull     196
     185: pop
     186: new           #40                 // class java/lang/IllegalStateException
     189: dup
     190: ldc           #132                // String Three not found
     192: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
     195: athrow
     196: areturn

  public static final java.util.List<java.lang.Character> find_two_chars(java.util.List<? extends java.util.List<java.lang.Character>>, java.util.List<java.lang.Character>, java.util.List<java.lang.Character>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: ldc           #137                // String threeChars
       9: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      12: aload_2
      13: ldc           #139                // String fiveChars
      15: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      18: aload_0
      19: checkcast     #18                 // class java/lang/Iterable
      22: astore_3
      23: nop
      24: iconst_0
      25: istore        4
      27: aload_3
      28: astore        5
      30: new           #67                 // class java/util/ArrayList
      33: dup
      34: invokespecial #70                 // Method java/util/ArrayList."<init>":()V
      37: checkcast     #72                 // class java/util/Collection
      40: astore        6
      42: iconst_0
      43: istore        7
      45: aload         5
      47: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      52: astore        8
      54: aload         8
      56: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      61: ifeq          115
      64: aload         8
      66: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      71: astore        9
      73: aload         9
      75: checkcast     #34                 // class java/util/List
      78: astore        10
      80: iconst_0
      81: istore        11
      83: aload         10
      85: invokeinterface #38,  1           // InterfaceMethod java/util/List.size:()I
      90: iconst_5
      91: if_icmpne     98
      94: iconst_1
      95: goto          99
      98: iconst_0
      99: ifeq          54
     102: aload         6
     104: aload         9
     106: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     111: pop
     112: goto          54
     115: aload         6
     117: checkcast     #34                 // class java/util/List
     120: nop
     121: checkcast     #18                 // class java/lang/Iterable
     124: astore_3
     125: nop
     126: iconst_0
     127: istore        4
     129: aload_3
     130: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     135: astore        5
     137: aload         5
     139: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     144: ifeq          197
     147: aload         5
     149: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     154: astore        6
     156: aload         6
     158: checkcast     #34                 // class java/util/List
     161: astore        7
     163: iconst_0
     164: istore        8
     166: aload         7
     168: aload_1
     169: invokestatic  #104                // Method kotlin/jvm/internal/Intrinsics.areEqual:(Ljava/lang/Object;Ljava/lang/Object;)Z
     172: ifne          188
     175: aload         7
     177: aload_2
     178: invokestatic  #104                // Method kotlin/jvm/internal/Intrinsics.areEqual:(Ljava/lang/Object;Ljava/lang/Object;)Z
     181: ifne          188
     184: iconst_1
     185: goto          189
     188: iconst_0
     189: ifeq          137
     192: aload         6
     194: goto          198
     197: aconst_null
     198: checkcast     #34                 // class java/util/List
     201: dup
     202: ifnonnull     216
     205: pop
     206: new           #40                 // class java/lang/IllegalStateException
     209: dup
     210: ldc           #132                // String Three not found
     212: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
     215: athrow
     216: areturn

  public static final java.util.Map<java.util.List<java.lang.Character>, java.lang.Character> findMappings(java.util.List<? extends java.util.List<java.lang.Character>>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_0
       7: invokestatic  #146                // Method find_one_chars:(Ljava/util/List;)Ljava/util/List;
      10: checkcast     #18                 // class java/lang/Iterable
      13: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
      16: astore_1
      17: aload_0
      18: invokestatic  #154                // Method find_four_chars:(Ljava/util/List;)Ljava/util/List;
      21: checkcast     #18                 // class java/lang/Iterable
      24: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
      27: astore_2
      28: aload_0
      29: invokestatic  #156                // Method find_seven_chars:(Ljava/util/List;)Ljava/util/List;
      32: checkcast     #18                 // class java/lang/Iterable
      35: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
      38: astore_3
      39: aload_0
      40: invokestatic  #158                // Method find_eight_chars:(Ljava/util/List;)Ljava/util/List;
      43: checkcast     #18                 // class java/lang/Iterable
      46: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
      49: astore        4
      51: aload_0
      52: aload_2
      53: invokestatic  #160                // Method find_nine_chars:(Ljava/util/List;Ljava/util/List;)Ljava/util/List;
      56: checkcast     #18                 // class java/lang/Iterable
      59: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
      62: astore        5
      64: aload_0
      65: aload_1
      66: aload         5
      68: invokestatic  #162                // Method find_zero_chars:(Ljava/util/List;Ljava/util/List;Ljava/util/List;)Ljava/util/List;
      71: checkcast     #18                 // class java/lang/Iterable
      74: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
      77: astore        6
      79: aload_0
      80: aload         5
      82: aload         6
      84: invokestatic  #164                // Method find_six_chars:(Ljava/util/List;Ljava/util/List;Ljava/util/List;)Ljava/util/List;
      87: checkcast     #18                 // class java/lang/Iterable
      90: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
      93: astore        7
      95: aload_0
      96: aload_3
      97: invokestatic  #166                // Method find_three_chars:(Ljava/util/List;Ljava/util/List;)Ljava/util/List;
     100: checkcast     #18                 // class java/lang/Iterable
     103: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     106: astore        8
     108: aload_0
     109: aload         7
     111: invokestatic  #168                // Method find_five_chars:(Ljava/util/List;Ljava/util/List;)Ljava/util/List;
     114: checkcast     #18                 // class java/lang/Iterable
     117: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     120: astore        9
     122: aload_0
     123: aload         8
     125: aload         9
     127: invokestatic  #170                // Method find_two_chars:(Ljava/util/List;Ljava/util/List;Ljava/util/List;)Ljava/util/List;
     130: checkcast     #18                 // class java/lang/Iterable
     133: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     136: astore        10
     138: bipush        10
     140: anewarray     #172                // class kotlin/Pair
     143: astore        12
     145: aload         12
     147: iconst_0
     148: aload         6
     150: checkcast     #18                 // class java/lang/Iterable
     153: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     156: bipush        48
     158: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     161: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     164: aastore
     165: aload         12
     167: iconst_1
     168: aload_1
     169: checkcast     #18                 // class java/lang/Iterable
     172: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     175: bipush        49
     177: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     180: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     183: aastore
     184: aload         12
     186: iconst_2
     187: aload         10
     189: checkcast     #18                 // class java/lang/Iterable
     192: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     195: bipush        50
     197: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     200: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     203: aastore
     204: aload         12
     206: iconst_3
     207: aload         8
     209: checkcast     #18                 // class java/lang/Iterable
     212: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     215: bipush        51
     217: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     220: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     223: aastore
     224: aload         12
     226: iconst_4
     227: aload_2
     228: checkcast     #18                 // class java/lang/Iterable
     231: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     234: bipush        52
     236: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     239: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     242: aastore
     243: aload         12
     245: iconst_5
     246: aload         9
     248: checkcast     #18                 // class java/lang/Iterable
     251: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     254: bipush        53
     256: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     259: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     262: aastore
     263: aload         12
     265: bipush        6
     267: aload         7
     269: checkcast     #18                 // class java/lang/Iterable
     272: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     275: bipush        54
     277: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     280: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     283: aastore
     284: aload         12
     286: bipush        7
     288: aload_3
     289: checkcast     #18                 // class java/lang/Iterable
     292: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     295: bipush        55
     297: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     300: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     303: aastore
     304: aload         12
     306: bipush        8
     308: aload         4
     310: checkcast     #18                 // class java/lang/Iterable
     313: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     316: bipush        56
     318: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     321: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     324: aastore
     325: aload         12
     327: bipush        9
     329: aload         5
     331: checkcast     #18                 // class java/lang/Iterable
     334: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     337: bipush        57
     339: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     342: invokestatic  #184                // Method kotlin/TuplesKt.to:(Ljava/lang/Object;Ljava/lang/Object;)Lkotlin/Pair;
     345: aastore
     346: aload         12
     348: invokestatic  #190                // Method kotlin/collections/MapsKt.mapOf:([Lkotlin/Pair;)Ljava/util/Map;
     351: astore        11
     353: aload         11
     355: invokeinterface #196,  1          // InterfaceMethod java/util/Map.keySet:()Ljava/util/Set;
     360: invokeinterface #199,  1          // InterfaceMethod java/util/Set.size:()I
     365: bipush        10
     367: if_icmpeq     490
     370: aload         11
     372: invokeinterface #203,  1          // InterfaceMethod java/util/Map.values:()Ljava/util/Collection;
     377: checkcast     #18                 // class java/lang/Iterable
     380: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     383: checkcast     #18                 // class java/lang/Iterable
     386: astore        12
     388: iconst_0
     389: istore        13
     391: aload         12
     393: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     398: astore        14
     400: aload         14
     402: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     407: ifeq          445
     410: aload         14
     412: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     417: astore        15
     419: aload         15
     421: checkcast     #174                // class java/lang/Character
     424: invokevirtual #207                // Method java/lang/Character.charValue:()C
     427: istore        16
     429: iconst_0
     430: istore        17
     432: getstatic     #213                // Field java/lang/System.out:Ljava/io/PrintStream;
     435: iload         16
     437: invokevirtual #219                // Method java/io/PrintStream.println:(C)V
     440: nop
     441: nop
     442: goto          400
     445: nop
     446: new           #221                // class java/lang/StringBuilder
     449: dup
     450: invokespecial #222                // Method java/lang/StringBuilder."<init>":()V
     453: ldc           #224                // String 3 =
     455: invokevirtual #228                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     458: aload         11
     460: aload         8
     462: invokeinterface #232,  2          // InterfaceMethod java/util/Map.get:(Ljava/lang/Object;)Ljava/lang/Object;
     467: invokevirtual #235                // Method java/lang/StringBuilder.append:(Ljava/lang/Object;)Ljava/lang/StringBuilder;
     470: invokevirtual #239                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
     473: getstatic     #213                // Field java/lang/System.out:Ljava/io/PrintStream;
     476: swap
     477: invokevirtual #242                // Method java/io/PrintStream.println:(Ljava/lang/Object;)V
     480: new           #40                 // class java/lang/IllegalStateException
     483: dup
     484: ldc           #244                // String Map size is not 10
     486: invokespecial #46                 // Method java/lang/IllegalStateException."<init>":(Ljava/lang/String;)V
     489: athrow
     490: aload         11
     492: areturn

  public static final java.util.List<java.lang.Character> translate(java.util.List<? extends java.util.List<java.lang.Character>>, java.util.List<? extends java.util.List<java.lang.Character>>);
    Code:
       0: aload_0
       1: ldc           #10                 // String input
       3: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: ldc_w         #264                // String value
      10: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
      13: aload_0
      14: invokestatic  #266                // Method findMappings:(Ljava/util/List;)Ljava/util/Map;
      17: astore_2
      18: aload_1
      19: checkcast     #18                 // class java/lang/Iterable
      22: astore_3
      23: iconst_0
      24: istore        4
      26: aload_3
      27: astore        5
      29: new           #67                 // class java/util/ArrayList
      32: dup
      33: aload_3
      34: bipush        10
      36: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      39: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
      42: checkcast     #72                 // class java/util/Collection
      45: astore        6
      47: iconst_0
      48: istore        7
      50: aload         5
      52: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      57: astore        8
      59: aload         8
      61: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      66: ifeq          137
      69: aload         8
      71: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      76: astore        9
      78: aload         6
      80: aload         9
      82: checkcast     #34                 // class java/util/List
      85: astore        10
      87: astore        12
      89: iconst_0
      90: istore        11
      92: aload_2
      93: aload         10
      95: checkcast     #18                 // class java/lang/Iterable
      98: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     101: invokeinterface #232,  2          // InterfaceMethod java/util/Map.get:(Ljava/lang/Object;)Ljava/lang/Object;
     106: checkcast     #174                // class java/lang/Character
     109: dup
     110: ifnull        119
     113: invokevirtual #207                // Method java/lang/Character.charValue:()C
     116: goto          122
     119: pop
     120: bipush        46
     122: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     125: aload         12
     127: swap
     128: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     133: pop
     134: goto          59
     137: aload         6
     139: checkcast     #34                 // class java/util/List
     142: nop
     143: areturn

  public static final java.util.List<kotlin.Pair<java.util.List<java.util.List<java.lang.Character>>, java.util.List<java.util.List<java.lang.Character>>>> readInput(java.lang.String);
    Code:
       0: aload_0
       1: ldc_w         #286                // String filename
       4: invokestatic  #16                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       7: new           #288                // class java/io/File
      10: dup
      11: aload_0
      12: invokespecial #289                // Method java/io/File."<init>":(Ljava/lang/String;)V
      15: aconst_null
      16: iconst_1
      17: aconst_null
      18: invokestatic  #295                // Method kotlin/io/FilesKt.readLines$default:(Ljava/io/File;Ljava/nio/charset/Charset;ILjava/lang/Object;)Ljava/util/List;
      21: checkcast     #18                 // class java/lang/Iterable
      24: astore_1
      25: nop
      26: iconst_0
      27: istore_2
      28: aload_1
      29: astore_3
      30: new           #67                 // class java/util/ArrayList
      33: dup
      34: aload_1
      35: bipush        10
      37: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      40: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
      43: checkcast     #72                 // class java/util/Collection
      46: astore        4
      48: iconst_0
      49: istore        5
      51: aload_3
      52: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      57: astore        6
      59: aload         6
      61: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      66: ifeq          485
      69: aload         6
      71: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      76: astore        7
      78: aload         4
      80: aload         7
      82: checkcast     #297                // class java/lang/String
      85: astore        8
      87: astore        24
      89: iconst_0
      90: istore        9
      92: aload         8
      94: checkcast     #299                // class java/lang/CharSequence
      97: iconst_1
      98: anewarray     #297                // class java/lang/String
     101: astore        10
     103: aload         10
     105: iconst_0
     106: ldc_w         #301                // String |
     109: aastore
     110: aload         10
     112: iconst_0
     113: iconst_0
     114: bipush        6
     116: aconst_null
     117: invokestatic  #307                // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[Ljava/lang/String;ZIILjava/lang/Object;)Ljava/util/List;
     120: astore        11
     122: aload         11
     124: iconst_0
     125: invokeinterface #310,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     130: checkcast     #297                // class java/lang/String
     133: astore        10
     135: aload         11
     137: iconst_1
     138: invokeinterface #310,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     143: checkcast     #297                // class java/lang/String
     146: astore        12
     148: aload         10
     150: checkcast     #299                // class java/lang/CharSequence
     153: invokestatic  #314                // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
     156: invokevirtual #315                // Method java/lang/Object.toString:()Ljava/lang/String;
     159: checkcast     #299                // class java/lang/CharSequence
     162: iconst_1
     163: anewarray     #297                // class java/lang/String
     166: astore        13
     168: aload         13
     170: iconst_0
     171: ldc_w         #317                // String
     174: aastore
     175: aload         13
     177: iconst_0
     178: iconst_0
     179: bipush        6
     181: aconst_null
     182: invokestatic  #307                // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[Ljava/lang/String;ZIILjava/lang/Object;)Ljava/util/List;
     185: checkcast     #18                 // class java/lang/Iterable
     188: astore        13
     190: iconst_0
     191: istore        14
     193: aload         13
     195: astore        15
     197: new           #67                 // class java/util/ArrayList
     200: dup
     201: aload         13
     203: bipush        10
     205: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     208: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
     211: checkcast     #72                 // class java/util/Collection
     214: astore        16
     216: iconst_0
     217: istore        17
     219: aload         15
     221: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     226: astore        18
     228: aload         18
     230: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     235: ifeq          294
     238: aload         18
     240: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     245: astore        19
     247: aload         16
     249: aload         19
     251: checkcast     #297                // class java/lang/String
     254: astore        20
     256: astore        21
     258: iconst_0
     259: istore        22
     261: aload         20
     263: invokevirtual #321                // Method java/lang/String.toCharArray:()[C
     266: dup
     267: ldc_w         #323                // String toCharArray(...)
     270: invokestatic  #326                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     273: invokestatic  #332                // Method kotlin/collections/ArraysKt.toList:([C)Ljava/util/List;
     276: checkcast     #18                 // class java/lang/Iterable
     279: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     282: aload         21
     284: swap
     285: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     290: pop
     291: goto          228
     294: aload         16
     296: checkcast     #34                 // class java/util/List
     299: nop
     300: aload         12
     302: checkcast     #299                // class java/lang/CharSequence
     305: invokestatic  #314                // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
     308: invokevirtual #315                // Method java/lang/Object.toString:()Ljava/lang/String;
     311: checkcast     #299                // class java/lang/CharSequence
     314: iconst_1
     315: anewarray     #297                // class java/lang/String
     318: astore        13
     320: aload         13
     322: iconst_0
     323: ldc_w         #317                // String
     326: aastore
     327: aload         13
     329: iconst_0
     330: iconst_0
     331: bipush        6
     333: aconst_null
     334: invokestatic  #307                // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[Ljava/lang/String;ZIILjava/lang/Object;)Ljava/util/List;
     337: checkcast     #18                 // class java/lang/Iterable
     340: astore        13
     342: astore        21
     344: iconst_0
     345: istore        14
     347: aload         13
     349: astore        15
     351: new           #67                 // class java/util/ArrayList
     354: dup
     355: aload         13
     357: bipush        10
     359: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     362: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
     365: checkcast     #72                 // class java/util/Collection
     368: astore        16
     370: iconst_0
     371: istore        17
     373: aload         15
     375: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     380: astore        18
     382: aload         18
     384: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     389: ifeq          448
     392: aload         18
     394: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     399: astore        19
     401: aload         16
     403: aload         19
     405: checkcast     #297                // class java/lang/String
     408: astore        20
     410: astore        23
     412: iconst_0
     413: istore        22
     415: aload         20
     417: invokevirtual #321                // Method java/lang/String.toCharArray:()[C
     420: dup
     421: ldc_w         #323                // String toCharArray(...)
     424: invokestatic  #326                // Method kotlin/jvm/internal/Intrinsics.checkNotNullExpressionValue:(Ljava/lang/Object;Ljava/lang/String;)V
     427: invokestatic  #332                // Method kotlin/collections/ArraysKt.toList:([C)Ljava/util/List;
     430: checkcast     #18                 // class java/lang/Iterable
     433: invokestatic  #152                // Method kotlin/collections/CollectionsKt.sorted:(Ljava/lang/Iterable;)Ljava/util/List;
     436: aload         23
     438: swap
     439: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     444: pop
     445: goto          382
     448: aload         16
     450: checkcast     #34                 // class java/util/List
     453: nop
     454: aload         21
     456: swap
     457: astore        25
     459: astore        26
     461: new           #172                // class kotlin/Pair
     464: dup
     465: aload         26
     467: aload         25
     469: invokespecial #335                // Method kotlin/Pair."<init>":(Ljava/lang/Object;Ljava/lang/Object;)V
     472: nop
     473: aload         24
     475: swap
     476: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     481: pop
     482: goto          59
     485: aload         4
     487: checkcast     #34                 // class java/util/List
     490: nop
     491: areturn

  public static java.util.List readInput$default(java.lang.String, int, java.lang.Object);
    Code:
       0: iload_1
       1: iconst_1
       2: iand
       3: ifeq          10
       6: ldc_w         #346                // String day8.txt
       9: astore_0
      10: aload_0
      11: invokestatic  #348                // Method readInput:(Ljava/lang/String;)Ljava/util/List;
      14: areturn

  public static final void part1();
    Code:
       0: aconst_null
       1: iconst_1
       2: aconst_null
       3: invokestatic  #351                // Method readInput$default:(Ljava/lang/String;ILjava/lang/Object;)Ljava/util/List;
       6: astore_0
       7: aload_0
       8: checkcast     #18                 // class java/lang/Iterable
      11: astore_2
      12: iconst_0
      13: istore_3
      14: aload_2
      15: astore        4
      17: new           #67                 // class java/util/ArrayList
      20: dup
      21: aload_2
      22: bipush        10
      24: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      27: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
      30: checkcast     #72                 // class java/util/Collection
      33: astore        5
      35: iconst_0
      36: istore        6
      38: aload         4
      40: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      45: astore        7
      47: aload         7
      49: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      54: ifeq          119
      57: aload         7
      59: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      64: astore        8
      66: aload         5
      68: aload         8
      70: checkcast     #172                // class kotlin/Pair
      73: astore        9
      75: astore        16
      77: iconst_0
      78: istore        10
      80: aload         9
      82: invokevirtual #354                // Method kotlin/Pair.component1:()Ljava/lang/Object;
      85: checkcast     #34                 // class java/util/List
      88: astore        11
      90: aload         9
      92: invokevirtual #357                // Method kotlin/Pair.component2:()Ljava/lang/Object;
      95: checkcast     #34                 // class java/util/List
      98: astore        12
     100: aload         11
     102: aload         12
     104: invokestatic  #359                // Method translate:(Ljava/util/List;Ljava/util/List;)Ljava/util/List;
     107: aload         16
     109: swap
     110: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     115: pop
     116: goto          47
     119: aload         5
     121: checkcast     #34                 // class java/util/List
     124: nop
     125: checkcast     #18                 // class java/lang/Iterable
     128: astore_2
     129: iconst_0
     130: istore_3
     131: aload_2
     132: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     137: astore        4
     139: aload         4
     141: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     146: ifeq          338
     149: aload         4
     151: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     156: astore        5
     158: iload_3
     159: aload         5
     161: checkcast     #34                 // class java/util/List
     164: astore        6
     166: istore        16
     168: iconst_0
     169: istore        7
     171: aload         6
     173: checkcast     #18                 // class java/lang/Iterable
     176: astore        8
     178: iconst_0
     179: istore        9
     181: aload         8
     183: instanceof    #72                 // class java/util/Collection
     186: ifeq          206
     189: aload         8
     191: checkcast     #72                 // class java/util/Collection
     194: invokeinterface #362,  1          // InterfaceMethod java/util/Collection.isEmpty:()Z
     199: ifeq          206
     202: iconst_0
     203: goto          326
     206: iconst_0
     207: istore        10
     209: aload         8
     211: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     216: astore        11
     218: aload         11
     220: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     225: ifeq          324
     228: aload         11
     230: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     235: astore        12
     237: aload         12
     239: checkcast     #174                // class java/lang/Character
     242: invokevirtual #207                // Method java/lang/Character.charValue:()C
     245: istore        13
     247: iconst_0
     248: istore        14
     250: iconst_4
     251: anewarray     #174                // class java/lang/Character
     254: astore        15
     256: aload         15
     258: iconst_0
     259: bipush        49
     261: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     264: aastore
     265: aload         15
     267: iconst_1
     268: bipush        52
     270: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     273: aastore
     274: aload         15
     276: iconst_2
     277: bipush        55
     279: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     282: aastore
     283: aload         15
     285: iconst_3
     286: bipush        56
     288: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     291: aastore
     292: aload         15
     294: invokestatic  #366                // Method kotlin/collections/CollectionsKt.listOf:([Ljava/lang/Object;)Ljava/util/List;
     297: iload         13
     299: invokestatic  #178                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     302: invokeinterface #369,  2          // InterfaceMethod java/util/List.contains:(Ljava/lang/Object;)Z
     307: ifeq          218
     310: iinc          10, 1
     313: iload         10
     315: ifge          218
     318: invokestatic  #372                // Method kotlin/collections/CollectionsKt.throwCountOverflow:()V
     321: goto          218
     324: iload         10
     326: nop
     327: istore        17
     329: iload         16
     331: iload         17
     333: iadd
     334: istore_3
     335: goto          139
     338: iload_3
     339: istore_1
     340: new           #221                // class java/lang/StringBuilder
     343: dup
     344: invokespecial #222                // Method java/lang/StringBuilder."<init>":()V
     347: ldc_w         #374                // String Digits:
     350: invokevirtual #228                // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
     353: iload_1
     354: invokevirtual #377                // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
     357: invokevirtual #239                // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
     360: getstatic     #213                // Field java/lang/System.out:Ljava/io/PrintStream;
     363: swap
     364: invokevirtual #242                // Method java/io/PrintStream.println:(Ljava/lang/Object;)V
     367: return

  public static final void part2();
    Code:
       0: aconst_null
       1: iconst_1
       2: aconst_null
       3: invokestatic  #351                // Method readInput$default:(Ljava/lang/String;ILjava/lang/Object;)Ljava/util/List;
       6: astore_0
       7: aload_0
       8: checkcast     #18                 // class java/lang/Iterable
      11: astore_2
      12: iconst_0
      13: istore_3
      14: aload_2
      15: astore        4
      17: new           #67                 // class java/util/ArrayList
      20: dup
      21: aload_2
      22: bipush        10
      24: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      27: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
      30: checkcast     #72                 // class java/util/Collection
      33: astore        5
      35: iconst_0
      36: istore        6
      38: aload         4
      40: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      45: astore        7
      47: aload         7
      49: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      54: ifeq          119
      57: aload         7
      59: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      64: astore        8
      66: aload         5
      68: aload         8
      70: checkcast     #172                // class kotlin/Pair
      73: astore        9
      75: astore        13
      77: iconst_0
      78: istore        10
      80: aload         9
      82: invokevirtual #354                // Method kotlin/Pair.component1:()Ljava/lang/Object;
      85: checkcast     #34                 // class java/util/List
      88: astore        11
      90: aload         9
      92: invokevirtual #357                // Method kotlin/Pair.component2:()Ljava/lang/Object;
      95: checkcast     #34                 // class java/util/List
      98: astore        12
     100: aload         11
     102: aload         12
     104: invokestatic  #359                // Method translate:(Ljava/util/List;Ljava/util/List;)Ljava/util/List;
     107: aload         13
     109: swap
     110: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     115: pop
     116: goto          47
     119: aload         5
     121: checkcast     #34                 // class java/util/List
     124: nop
     125: checkcast     #18                 // class java/lang/Iterable
     128: astore_2
     129: nop
     130: iconst_0
     131: istore_3
     132: aload_2
     133: astore        4
     135: new           #67                 // class java/util/ArrayList
     138: dup
     139: aload_2
     140: bipush        10
     142: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     145: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
     148: checkcast     #72                 // class java/util/Collection
     151: astore        5
     153: iconst_0
     154: istore        6
     156: aload         4
     158: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     163: astore        7
     165: aload         7
     167: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     172: ifeq          239
     175: aload         7
     177: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     182: astore        8
     184: aload         5
     186: aload         8
     188: checkcast     #34                 // class java/util/List
     191: astore        9
     193: astore        13
     195: iconst_0
     196: istore        10
     198: aload         9
     200: checkcast     #18                 // class java/lang/Iterable
     203: ldc_w         #389                // String
     206: checkcast     #299                // class java/lang/CharSequence
     209: aconst_null
     210: aconst_null
     211: iconst_0
     212: aconst_null
     213: aconst_null
     214: bipush        62
     216: aconst_null
     217: invokestatic  #393                // 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;
     220: invokestatic  #399                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     223: nop
     224: invokestatic  #402                // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     227: aload         13
     229: swap
     230: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     235: pop
     236: goto          165
     239: aload         5
     241: checkcast     #34                 // class java/util/List
     244: nop
     245: checkcast     #18                 // class java/lang/Iterable
     248: invokestatic  #406                // Method kotlin/collections/CollectionsKt.sumOfInt:(Ljava/lang/Iterable;)I
     251: istore_1
     252: getstatic     #213                // Field java/lang/System.out:Ljava/io/PrintStream;
     255: iload_1
     256: invokevirtual #409                // Method java/io/PrintStream.print:(I)V
     259: return

  public static final void part2_debug();
    Code:
       0: ldc_w         #414                // String day8_debug.txt
       3: invokestatic  #348                // Method readInput:(Ljava/lang/String;)Ljava/util/List;
       6: astore_0
       7: aload_0
       8: checkcast     #18                 // class java/lang/Iterable
      11: astore_1
      12: iconst_0
      13: istore_2
      14: aload_1
      15: astore_3
      16: new           #67                 // class java/util/ArrayList
      19: dup
      20: aload_1
      21: bipush        10
      23: invokestatic  #270                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      26: invokespecial #273                // Method java/util/ArrayList."<init>":(I)V
      29: checkcast     #72                 // class java/util/Collection
      32: astore        4
      34: iconst_0
      35: istore        5
      37: aload_3
      38: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      43: astore        6
      45: aload         6
      47: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      52: ifeq          117
      55: aload         6
      57: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      62: astore        7
      64: aload         4
      66: aload         7
      68: checkcast     #172                // class kotlin/Pair
      71: astore        8
      73: astore        12
      75: iconst_0
      76: istore        9
      78: aload         8
      80: invokevirtual #354                // Method kotlin/Pair.component1:()Ljava/lang/Object;
      83: checkcast     #34                 // class java/util/List
      86: astore        10
      88: aload         8
      90: invokevirtual #357                // Method kotlin/Pair.component2:()Ljava/lang/Object;
      93: checkcast     #34                 // class java/util/List
      96: astore        11
      98: aload         10
     100: aload         11
     102: invokestatic  #359                // Method translate:(Ljava/util/List;Ljava/util/List;)Ljava/util/List;
     105: aload         12
     107: swap
     108: invokeinterface #76,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     113: pop
     114: goto          45
     117: aload         4
     119: checkcast     #34                 // class java/util/List
     122: nop
     123: checkcast     #18                 // class java/lang/Iterable
     126: astore_1
     127: nop
     128: iconst_0
     129: istore_2
     130: aload_1
     131: invokeinterface #22,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     136: astore_3
     137: aload_3
     138: invokeinterface #28,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     143: ifeq          198
     146: aload_3
     147: invokeinterface #32,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     152: astore        4
     154: aload         4
     156: checkcast     #34                 // class java/util/List
     159: astore        5
     161: iconst_0
     162: istore        6
     164: aload         5
     166: checkcast     #18                 // class java/lang/Iterable
     169: ldc_w         #389                // String
     172: checkcast     #299                // class java/lang/CharSequence
     175: aconst_null
     176: aconst_null
     177: iconst_0
     178: aconst_null
     179: aconst_null
     180: bipush        62
     182: aconst_null
     183: invokestatic  #393                // 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;
     186: getstatic     #213                // Field java/lang/System.out:Ljava/io/PrintStream;
     189: swap
     190: invokevirtual #242                // Method java/io/PrintStream.println:(Ljava/lang/Object;)V
     193: nop
     194: nop
     195: goto          137
     198: nop
     199: return

  public static final void main();
    Code:
       0: invokestatic  #420                // Method part2:()V
       3: return

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