class Day005 {

    data class Instruction(val count: Int, val source: Int, val target: Int)

    fun part1(lines: List<String>): String {
        val numberOfContainers = lines.first { it.trim().startsWith("1") }.trim().last().digitToInt()

        val containers = List(numberOfContainers) { ArrayDeque<Char>() }
        createContainers(lines, containers as MutableList<ArrayDeque<Char>>)

        val instructions: List<Instruction> = getInstructions(lines)

        instructions.forEach { instruction ->
            repeat(instruction.count) {
                if (containers[instruction.source - 1].isNotEmpty()) {
                    containers[instruction.target - 1].addFirst(containers[instruction.source - 1].removeFirst())
                }
            }
        }

        return containers.map { it.first() }.joinToString("")
    }

    fun part2(lines: List<String>): String {
        val numberOfContainers = lines.first { it.trim().startsWith("1") }.trim().last().digitToInt()
        val containers = List(numberOfContainers) { ArrayDeque<Char>() }.toMutableList()

        createContainers(lines, containers)

        val instructions: List<Instruction> = getInstructions(lines)

        instructions.forEach { instr ->
            containers[instr.target - 1].addAll(0, containers[instr.source - 1].take(instr.count))
            repeat(instr.count) { containers[instr.source - 1].removeFirst() }
        }

        return containers.map { it.first() }.joinToString("")
    }

    private fun getInstructions(lines: List<String>): List<Instruction> {
        val regex = """move (\d+) from (\d+) to (\d+)""".toRegex()
        val instructions: List<Instruction> = lines
            .dropWhile { !it.trim().startsWith("move") }
            .map {
                val matchResult = regex.find(it)
                val (count, source, target) = matchResult!!.destructured
                Instruction(count.toInt(), source.toInt(), target.toInt())
            }
        return instructions
    }

    private fun createContainers(
        lines: List<String>,
        containers: MutableList<ArrayDeque<Char>>,
    ) {
        lines
            .takeWhile { !it.trim().startsWith("1") }
            .map { line ->
                line.slice(1..line.length step 4)
                    .mapIndexed { containerNumber, value ->
                        if (value.isLetter()) containers[containerNumber].addLast(value)
                    }
            }
    }
}

Compiled from "Day005.kt"
public final class Day005$Instruction {
  private final int count;

  private final int source;

  private final int target;

  public Day005$Instruction(int, int, int);
    Code:
       0: aload_0
       1: invokespecial #9                  // Method java/lang/Object."<init>":()V
       4: aload_0
       5: iload_1
       6: putfield      #13                 // Field count:I
       9: aload_0
      10: iload_2
      11: putfield      #16                 // Field source:I
      14: aload_0
      15: iload_3
      16: putfield      #19                 // Field target:I
      19: return

  public final int getCount();
    Code:
       0: aload_0
       1: getfield      #13                 // Field count:I
       4: ireturn

  public final int getSource();
    Code:
       0: aload_0
       1: getfield      #16                 // Field source:I
       4: ireturn

  public final int getTarget();
    Code:
       0: aload_0
       1: getfield      #19                 // Field target:I
       4: ireturn

  public final int component1();
    Code:
       0: aload_0
       1: getfield      #13                 // Field count:I
       4: ireturn

  public final int component2();
    Code:
       0: aload_0
       1: getfield      #16                 // Field source:I
       4: ireturn

  public final int component3();
    Code:
       0: aload_0
       1: getfield      #19                 // Field target:I
       4: ireturn

  public final Day005$Instruction copy(int, int, int);
    Code:
       0: new           #2                  // class Day005$Instruction
       3: dup
       4: iload_1
       5: iload_2
       6: iload_3
       7: invokespecial #33                 // Method "<init>":(III)V
      10: areturn

  public static Day005$Instruction copy$default(Day005$Instruction, int, int, int, int, java.lang.Object);
    Code:
       0: iload         4
       2: iconst_1
       3: iand
       4: ifeq          12
       7: aload_0
       8: getfield      #13                 // Field count:I
      11: istore_1
      12: iload         4
      14: iconst_2
      15: iand
      16: ifeq          24
      19: aload_0
      20: getfield      #16                 // Field source:I
      23: istore_2
      24: iload         4
      26: iconst_4
      27: iand
      28: ifeq          36
      31: aload_0
      32: getfield      #19                 // Field target:I
      35: istore_3
      36: aload_0
      37: iload_1
      38: iload_2
      39: iload_3
      40: invokevirtual #37                 // Method copy:(III)LDay005$Instruction;
      43: areturn

  public java.lang.String toString();
    Code:
       0: new           #41                 // class java/lang/StringBuilder
       3: dup
       4: invokespecial #42                 // Method java/lang/StringBuilder."<init>":()V
       7: ldc           #44                 // String Instruction(count=
       9: invokevirtual #48                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      12: aload_0
      13: getfield      #13                 // Field count:I
      16: invokevirtual #51                 // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      19: ldc           #53                 // String , source=
      21: invokevirtual #48                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      24: aload_0
      25: getfield      #16                 // Field source:I
      28: invokevirtual #51                 // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      31: ldc           #55                 // String , target=
      33: invokevirtual #48                 // Method java/lang/StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
      36: aload_0
      37: getfield      #19                 // Field target:I
      40: invokevirtual #51                 // Method java/lang/StringBuilder.append:(I)Ljava/lang/StringBuilder;
      43: bipush        41
      45: invokevirtual #58                 // Method java/lang/StringBuilder.append:(C)Ljava/lang/StringBuilder;
      48: invokevirtual #60                 // Method java/lang/StringBuilder.toString:()Ljava/lang/String;
      51: areturn

  public int hashCode();
    Code:
       0: aload_0
       1: getfield      #13                 // Field count:I
       4: invokestatic  #66                 // Method java/lang/Integer.hashCode:(I)I
       7: istore_1
       8: iload_1
       9: bipush        31
      11: imul
      12: aload_0
      13: getfield      #16                 // Field source:I
      16: invokestatic  #66                 // Method java/lang/Integer.hashCode:(I)I
      19: iadd
      20: istore_1
      21: iload_1
      22: bipush        31
      24: imul
      25: aload_0
      26: getfield      #19                 // Field target:I
      29: invokestatic  #66                 // Method java/lang/Integer.hashCode:(I)I
      32: iadd
      33: istore_1
      34: iload_1
      35: ireturn

  public boolean equals(java.lang.Object);
    Code:
       0: aload_0
       1: aload_1
       2: if_acmpne     7
       5: iconst_1
       6: ireturn
       7: aload_1
       8: instanceof    #2                  // class Day005$Instruction
      11: ifne          16
      14: iconst_0
      15: ireturn
      16: aload_1
      17: checkcast     #2                  // class Day005$Instruction
      20: astore_2
      21: aload_0
      22: getfield      #13                 // Field count:I
      25: aload_2
      26: getfield      #13                 // Field count:I
      29: if_icmpeq     34
      32: iconst_0
      33: ireturn
      34: aload_0
      35: getfield      #16                 // Field source:I
      38: aload_2
      39: getfield      #16                 // Field source:I
      42: if_icmpeq     47
      45: iconst_0
      46: ireturn
      47: aload_0
      48: getfield      #19                 // Field target:I
      51: aload_2
      52: getfield      #19                 // Field target:I
      55: if_icmpeq     60
      58: iconst_0
      59: ireturn
      60: iconst_1
      61: ireturn
}

Compiled from "Day005.kt"
public final class Day005 {
  public Day005();
    Code:
       0: aload_0
       1: invokespecial #8                  // Method java/lang/Object."<init>":()V
       4: return

  public final java.lang.String part1(java.util.List<java.lang.String>);
    Code:
       0: aload_1
       1: ldc           #16                 // String lines
       3: invokestatic  #22                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: checkcast     #24                 // class java/lang/Iterable
      10: astore_3
      11: iconst_0
      12: istore        4
      14: aload_3
      15: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      20: astore        5
      22: aload         5
      24: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      29: ifeq          78
      32: aload         5
      34: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      39: astore        6
      41: aload         6
      43: checkcast     #40                 // class java/lang/String
      46: astore        7
      48: iconst_0
      49: istore        8
      51: aload         7
      53: checkcast     #42                 // class java/lang/CharSequence
      56: invokestatic  #48                 // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
      59: invokevirtual #52                 // Method java/lang/Object.toString:()Ljava/lang/String;
      62: ldc           #54                 // String 1
      64: iconst_0
      65: iconst_2
      66: aconst_null
      67: invokestatic  #58                 // Method kotlin/text/StringsKt.startsWith$default:(Ljava/lang/String;Ljava/lang/String;ZILjava/lang/Object;)Z
      70: ifeq          22
      73: aload         6
      75: goto          88
      78: new           #60                 // class java/util/NoSuchElementException
      81: dup
      82: ldc           #62                 // String Collection contains no element matching the predicate.
      84: invokespecial #65                 // Method java/util/NoSuchElementException."<init>":(Ljava/lang/String;)V
      87: athrow
      88: checkcast     #40                 // class java/lang/String
      91: checkcast     #42                 // class java/lang/CharSequence
      94: invokestatic  #48                 // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
      97: invokevirtual #52                 // Method java/lang/Object.toString:()Ljava/lang/String;
     100: checkcast     #42                 // class java/lang/CharSequence
     103: invokestatic  #69                 // Method kotlin/text/StringsKt.last:(Ljava/lang/CharSequence;)C
     106: invokestatic  #75                 // Method kotlin/text/CharsKt.digitToInt:(C)I
     109: istore_2
     110: new           #77                 // class java/util/ArrayList
     113: dup
     114: iload_2
     115: invokespecial #80                 // Method java/util/ArrayList."<init>":(I)V
     118: astore        4
     120: iconst_0
     121: istore        5
     123: iload         5
     125: iload_2
     126: if_icmpge     164
     129: iload         5
     131: istore        6
     133: aload         4
     135: iload         6
     137: istore        7
     139: astore        15
     141: iconst_0
     142: istore        8
     144: new           #82                 // class kotlin/collections/ArrayDeque
     147: dup
     148: invokespecial #83                 // Method kotlin/collections/ArrayDeque."<init>":()V
     151: aload         15
     153: swap
     154: invokevirtual #87                 // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
     157: pop
     158: iinc          5, 1
     161: goto          123
     164: aload         4
     166: checkcast     #89                 // class java/util/List
     169: astore_3
     170: aload_0
     171: aload_1
     172: aload_3
     173: invokestatic  #95                 // Method kotlin/jvm/internal/TypeIntrinsics.asMutableList:(Ljava/lang/Object;)Ljava/util/List;
     176: invokespecial #99                 // Method createContainers:(Ljava/util/List;Ljava/util/List;)V
     179: aload_0
     180: aload_1
     181: invokespecial #103                // Method getInstructions:(Ljava/util/List;)Ljava/util/List;
     184: astore        4
     186: aload         4
     188: checkcast     #24                 // class java/lang/Iterable
     191: astore        5
     193: iconst_0
     194: istore        6
     196: aload         5
     198: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     203: astore        7
     205: aload         7
     207: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     212: ifeq          340
     215: aload         7
     217: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     222: astore        8
     224: aload         8
     226: checkcast     #105                // class Day005$Instruction
     229: astore        9
     231: iconst_0
     232: istore        10
     234: aload         9
     236: invokevirtual #109                // Method Day005$Instruction.getCount:()I
     239: istore        11
     241: iconst_0
     242: istore        12
     244: iload         12
     246: iload         11
     248: if_icmpge     335
     251: iload         12
     253: istore        13
     255: iconst_0
     256: istore        14
     258: aload_3
     259: aload         9
     261: invokevirtual #112                // Method Day005$Instruction.getSource:()I
     264: iconst_1
     265: isub
     266: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     271: checkcast     #118                // class java/util/Collection
     274: invokeinterface #121,  1          // InterfaceMethod java/util/Collection.isEmpty:()Z
     279: ifne          286
     282: iconst_1
     283: goto          287
     286: iconst_0
     287: ifeq          328
     290: aload_3
     291: aload         9
     293: invokevirtual #124                // Method Day005$Instruction.getTarget:()I
     296: iconst_1
     297: isub
     298: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     303: checkcast     #82                 // class kotlin/collections/ArrayDeque
     306: aload_3
     307: aload         9
     309: invokevirtual #112                // Method Day005$Instruction.getSource:()I
     312: iconst_1
     313: isub
     314: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     319: checkcast     #82                 // class kotlin/collections/ArrayDeque
     322: invokevirtual #127                // Method kotlin/collections/ArrayDeque.removeFirst:()Ljava/lang/Object;
     325: invokevirtual #131                // Method kotlin/collections/ArrayDeque.addFirst:(Ljava/lang/Object;)V
     328: nop
     329: iinc          12, 1
     332: goto          244
     335: nop
     336: nop
     337: goto          205
     340: nop
     341: aload_3
     342: checkcast     #24                 // class java/lang/Iterable
     345: astore        5
     347: iconst_0
     348: istore        6
     350: aload         5
     352: astore        7
     354: new           #77                 // class java/util/ArrayList
     357: dup
     358: aload         5
     360: bipush        10
     362: invokestatic  #137                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     365: invokespecial #80                 // Method java/util/ArrayList."<init>":(I)V
     368: checkcast     #118                // class java/util/Collection
     371: astore        8
     373: iconst_0
     374: istore        9
     376: aload         7
     378: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     383: astore        10
     385: aload         10
     387: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     392: ifeq          444
     395: aload         10
     397: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     402: astore        11
     404: aload         8
     406: aload         11
     408: checkcast     #82                 // class kotlin/collections/ArrayDeque
     411: astore        12
     413: astore        15
     415: iconst_0
     416: istore        13
     418: aload         12
     420: invokevirtual #140                // Method kotlin/collections/ArrayDeque.first:()Ljava/lang/Object;
     423: checkcast     #142                // class java/lang/Character
     426: invokevirtual #146                // Method java/lang/Character.charValue:()C
     429: invokestatic  #150                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     432: aload         15
     434: swap
     435: invokeinterface #151,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     440: pop
     441: goto          385
     444: aload         8
     446: checkcast     #89                 // class java/util/List
     449: nop
     450: checkcast     #24                 // class java/lang/Iterable
     453: ldc           #153                // String
     455: checkcast     #42                 // class java/lang/CharSequence
     458: aconst_null
     459: aconst_null
     460: iconst_0
     461: aconst_null
     462: aconst_null
     463: bipush        62
     465: aconst_null
     466: invokestatic  #157                // 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;
     469: areturn

  public final java.lang.String part2(java.util.List<java.lang.String>);
    Code:
       0: aload_1
       1: ldc           #16                 // String lines
       3: invokestatic  #22                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: checkcast     #24                 // class java/lang/Iterable
      10: astore_3
      11: iconst_0
      12: istore        4
      14: aload_3
      15: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      20: astore        5
      22: aload         5
      24: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      29: ifeq          78
      32: aload         5
      34: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      39: astore        6
      41: aload         6
      43: checkcast     #40                 // class java/lang/String
      46: astore        7
      48: iconst_0
      49: istore        8
      51: aload         7
      53: checkcast     #42                 // class java/lang/CharSequence
      56: invokestatic  #48                 // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
      59: invokevirtual #52                 // Method java/lang/Object.toString:()Ljava/lang/String;
      62: ldc           #54                 // String 1
      64: iconst_0
      65: iconst_2
      66: aconst_null
      67: invokestatic  #58                 // Method kotlin/text/StringsKt.startsWith$default:(Ljava/lang/String;Ljava/lang/String;ZILjava/lang/Object;)Z
      70: ifeq          22
      73: aload         6
      75: goto          88
      78: new           #60                 // class java/util/NoSuchElementException
      81: dup
      82: ldc           #62                 // String Collection contains no element matching the predicate.
      84: invokespecial #65                 // Method java/util/NoSuchElementException."<init>":(Ljava/lang/String;)V
      87: athrow
      88: checkcast     #40                 // class java/lang/String
      91: checkcast     #42                 // class java/lang/CharSequence
      94: invokestatic  #48                 // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
      97: invokevirtual #52                 // Method java/lang/Object.toString:()Ljava/lang/String;
     100: checkcast     #42                 // class java/lang/CharSequence
     103: invokestatic  #69                 // Method kotlin/text/StringsKt.last:(Ljava/lang/CharSequence;)C
     106: invokestatic  #75                 // Method kotlin/text/CharsKt.digitToInt:(C)I
     109: istore_2
     110: new           #77                 // class java/util/ArrayList
     113: dup
     114: iload_2
     115: invokespecial #80                 // Method java/util/ArrayList."<init>":(I)V
     118: astore        4
     120: iconst_0
     121: istore        5
     123: iload         5
     125: iload_2
     126: if_icmpge     164
     129: iload         5
     131: istore        6
     133: aload         4
     135: iload         6
     137: istore        7
     139: astore        15
     141: iconst_0
     142: istore        8
     144: new           #82                 // class kotlin/collections/ArrayDeque
     147: dup
     148: invokespecial #83                 // Method kotlin/collections/ArrayDeque."<init>":()V
     151: aload         15
     153: swap
     154: invokevirtual #87                 // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
     157: pop
     158: iinc          5, 1
     161: goto          123
     164: aload         4
     166: checkcast     #89                 // class java/util/List
     169: checkcast     #118                // class java/util/Collection
     172: invokestatic  #191                // Method kotlin/collections/CollectionsKt.toMutableList:(Ljava/util/Collection;)Ljava/util/List;
     175: astore_3
     176: aload_0
     177: aload_1
     178: aload_3
     179: invokespecial #99                 // Method createContainers:(Ljava/util/List;Ljava/util/List;)V
     182: aload_0
     183: aload_1
     184: invokespecial #103                // Method getInstructions:(Ljava/util/List;)Ljava/util/List;
     187: astore        4
     189: aload         4
     191: checkcast     #24                 // class java/lang/Iterable
     194: astore        5
     196: iconst_0
     197: istore        6
     199: aload         5
     201: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     206: astore        7
     208: aload         7
     210: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     215: ifeq          340
     218: aload         7
     220: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     225: astore        8
     227: aload         8
     229: checkcast     #105                // class Day005$Instruction
     232: astore        9
     234: iconst_0
     235: istore        10
     237: aload_3
     238: aload         9
     240: invokevirtual #124                // Method Day005$Instruction.getTarget:()I
     243: iconst_1
     244: isub
     245: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     250: checkcast     #82                 // class kotlin/collections/ArrayDeque
     253: iconst_0
     254: aload_3
     255: aload         9
     257: invokevirtual #112                // Method Day005$Instruction.getSource:()I
     260: iconst_1
     261: isub
     262: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     267: checkcast     #24                 // class java/lang/Iterable
     270: aload         9
     272: invokevirtual #109                // Method Day005$Instruction.getCount:()I
     275: invokestatic  #195                // Method kotlin/collections/CollectionsKt.take:(Ljava/lang/Iterable;I)Ljava/util/List;
     278: checkcast     #118                // class java/util/Collection
     281: invokevirtual #199                // Method kotlin/collections/ArrayDeque.addAll:(ILjava/util/Collection;)Z
     284: pop
     285: aload         9
     287: invokevirtual #109                // Method Day005$Instruction.getCount:()I
     290: istore        11
     292: iconst_0
     293: istore        12
     295: iload         12
     297: iload         11
     299: if_icmpge     335
     302: iload         12
     304: istore        13
     306: iconst_0
     307: istore        14
     309: aload_3
     310: aload         9
     312: invokevirtual #112                // Method Day005$Instruction.getSource:()I
     315: iconst_1
     316: isub
     317: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     322: checkcast     #82                 // class kotlin/collections/ArrayDeque
     325: invokevirtual #127                // Method kotlin/collections/ArrayDeque.removeFirst:()Ljava/lang/Object;
     328: pop
     329: iinc          12, 1
     332: goto          295
     335: nop
     336: nop
     337: goto          208
     340: nop
     341: aload_3
     342: checkcast     #24                 // class java/lang/Iterable
     345: astore        5
     347: iconst_0
     348: istore        6
     350: aload         5
     352: astore        7
     354: new           #77                 // class java/util/ArrayList
     357: dup
     358: aload         5
     360: bipush        10
     362: invokestatic  #137                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     365: invokespecial #80                 // Method java/util/ArrayList."<init>":(I)V
     368: checkcast     #118                // class java/util/Collection
     371: astore        8
     373: iconst_0
     374: istore        9
     376: aload         7
     378: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     383: astore        10
     385: aload         10
     387: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     392: ifeq          444
     395: aload         10
     397: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     402: astore        11
     404: aload         8
     406: aload         11
     408: checkcast     #82                 // class kotlin/collections/ArrayDeque
     411: astore        12
     413: astore        15
     415: iconst_0
     416: istore        13
     418: aload         12
     420: invokevirtual #140                // Method kotlin/collections/ArrayDeque.first:()Ljava/lang/Object;
     423: checkcast     #142                // class java/lang/Character
     426: invokevirtual #146                // Method java/lang/Character.charValue:()C
     429: invokestatic  #150                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     432: aload         15
     434: swap
     435: invokeinterface #151,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     440: pop
     441: goto          385
     444: aload         8
     446: checkcast     #89                 // class java/util/List
     449: nop
     450: checkcast     #24                 // class java/lang/Iterable
     453: ldc           #153                // String
     455: checkcast     #42                 // class java/lang/CharSequence
     458: aconst_null
     459: aconst_null
     460: iconst_0
     461: aconst_null
     462: aconst_null
     463: bipush        62
     465: aconst_null
     466: invokestatic  #157                // 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;
     469: areturn

  private final java.util.List<Day005$Instruction> getInstructions(java.util.List<java.lang.String>);
    Code:
       0: new           #208                // class kotlin/text/Regex
       3: dup
       4: ldc           #210                // String move (\\d+) from (\\d+) to (\\d+)
       6: invokespecial #211                // Method kotlin/text/Regex."<init>":(Ljava/lang/String;)V
       9: astore_2
      10: aload_1
      11: checkcast     #24                 // class java/lang/Iterable
      14: astore        4
      16: nop
      17: iconst_0
      18: istore        5
      20: iconst_0
      21: istore        6
      23: new           #77                 // class java/util/ArrayList
      26: dup
      27: invokespecial #212                // Method java/util/ArrayList."<init>":()V
      30: astore        7
      32: aload         4
      34: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      39: astore        8
      41: aload         8
      43: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      48: ifeq          130
      51: aload         8
      53: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      58: astore        9
      60: iload         6
      62: ifeq          76
      65: aload         7
      67: aload         9
      69: invokevirtual #87                 // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
      72: pop
      73: goto          41
      76: aload         9
      78: checkcast     #40                 // class java/lang/String
      81: astore        10
      83: iconst_0
      84: istore        11
      86: aload         10
      88: checkcast     #42                 // class java/lang/CharSequence
      91: invokestatic  #48                 // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
      94: invokevirtual #52                 // Method java/lang/Object.toString:()Ljava/lang/String;
      97: ldc           #214                // String move
      99: iconst_0
     100: iconst_2
     101: aconst_null
     102: invokestatic  #58                 // Method kotlin/text/StringsKt.startsWith$default:(Ljava/lang/String;Ljava/lang/String;ZILjava/lang/Object;)Z
     105: ifne          112
     108: iconst_1
     109: goto          113
     112: iconst_0
     113: ifne          41
     116: aload         7
     118: aload         9
     120: invokevirtual #87                 // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
     123: pop
     124: iconst_1
     125: istore        6
     127: goto          41
     130: aload         7
     132: checkcast     #89                 // class java/util/List
     135: checkcast     #24                 // class java/lang/Iterable
     138: astore        4
     140: nop
     141: iconst_0
     142: istore        5
     144: aload         4
     146: astore        6
     148: new           #77                 // class java/util/ArrayList
     151: dup
     152: aload         4
     154: bipush        10
     156: invokestatic  #137                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     159: invokespecial #80                 // Method java/util/ArrayList."<init>":(I)V
     162: checkcast     #118                // class java/util/Collection
     165: astore        7
     167: iconst_0
     168: istore        8
     170: aload         6
     172: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     177: astore        9
     179: aload         9
     181: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     186: ifeq          336
     189: aload         9
     191: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     196: astore        10
     198: aload         7
     200: aload         10
     202: checkcast     #40                 // class java/lang/String
     205: astore        11
     207: astore        18
     209: iconst_0
     210: istore        12
     212: aload_2
     213: aload         11
     215: checkcast     #42                 // class java/lang/CharSequence
     218: iconst_0
     219: iconst_2
     220: aconst_null
     221: invokestatic  #218                // Method kotlin/text/Regex.find$default:(Lkotlin/text/Regex;Ljava/lang/CharSequence;IILjava/lang/Object;)Lkotlin/text/MatchResult;
     224: astore        13
     226: aload         13
     228: dup
     229: invokestatic  #221                // Method kotlin/jvm/internal/Intrinsics.checkNotNull:(Ljava/lang/Object;)V
     232: invokeinterface #227,  1          // InterfaceMethod kotlin/text/MatchResult.getDestructured:()Lkotlin/text/MatchResult$Destructured;
     237: astore        14
     239: aload         14
     241: invokevirtual #233                // Method kotlin/text/MatchResult$Destructured.getMatch:()Lkotlin/text/MatchResult;
     244: invokeinterface #237,  1          // InterfaceMethod kotlin/text/MatchResult.getGroupValues:()Ljava/util/List;
     249: iconst_1
     250: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     255: checkcast     #40                 // class java/lang/String
     258: astore        15
     260: aload         14
     262: invokevirtual #233                // Method kotlin/text/MatchResult$Destructured.getMatch:()Lkotlin/text/MatchResult;
     265: invokeinterface #237,  1          // InterfaceMethod kotlin/text/MatchResult.getGroupValues:()Ljava/util/List;
     270: iconst_2
     271: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     276: checkcast     #40                 // class java/lang/String
     279: astore        16
     281: aload         14
     283: invokevirtual #233                // Method kotlin/text/MatchResult$Destructured.getMatch:()Lkotlin/text/MatchResult;
     286: invokeinterface #237,  1          // InterfaceMethod kotlin/text/MatchResult.getGroupValues:()Ljava/util/List;
     291: iconst_3
     292: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     297: checkcast     #40                 // class java/lang/String
     300: astore        17
     302: new           #105                // class Day005$Instruction
     305: dup
     306: aload         15
     308: invokestatic  #243                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     311: aload         16
     313: invokestatic  #243                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     316: aload         17
     318: invokestatic  #243                // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     321: invokespecial #246                // Method Day005$Instruction."<init>":(III)V
     324: aload         18
     326: swap
     327: invokeinterface #151,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     332: pop
     333: goto          179
     336: aload         7
     338: checkcast     #89                 // class java/util/List
     341: nop
     342: astore_3
     343: aload_3
     344: areturn

  private final void createContainers(java.util.List<java.lang.String>, java.util.List<kotlin.collections.ArrayDeque<java.lang.Character>>);
    Code:
       0: aload_1
       1: checkcast     #24                 // class java/lang/Iterable
       4: astore_3
       5: nop
       6: iconst_0
       7: istore        4
       9: new           #77                 // class java/util/ArrayList
      12: dup
      13: invokespecial #212                // Method java/util/ArrayList."<init>":()V
      16: astore        5
      18: aload_3
      19: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      24: astore        6
      26: aload         6
      28: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      33: ifeq          99
      36: aload         6
      38: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      43: astore        7
      45: aload         7
      47: checkcast     #40                 // class java/lang/String
      50: astore        8
      52: iconst_0
      53: istore        9
      55: aload         8
      57: checkcast     #42                 // class java/lang/CharSequence
      60: invokestatic  #48                 // Method kotlin/text/StringsKt.trim:(Ljava/lang/CharSequence;)Ljava/lang/CharSequence;
      63: invokevirtual #52                 // Method java/lang/Object.toString:()Ljava/lang/String;
      66: ldc           #54                 // String 1
      68: iconst_0
      69: iconst_2
      70: aconst_null
      71: invokestatic  #58                 // Method kotlin/text/StringsKt.startsWith$default:(Ljava/lang/String;Ljava/lang/String;ZILjava/lang/Object;)Z
      74: ifne          81
      77: iconst_1
      78: goto          82
      81: iconst_0
      82: ifne          88
      85: goto          99
      88: aload         5
      90: aload         7
      92: invokevirtual #87                 // Method java/util/ArrayList.add:(Ljava/lang/Object;)Z
      95: pop
      96: goto          26
      99: aload         5
     101: checkcast     #89                 // class java/util/List
     104: checkcast     #24                 // class java/lang/Iterable
     107: astore_3
     108: nop
     109: iconst_0
     110: istore        4
     112: aload_3
     113: astore        5
     115: new           #77                 // class java/util/ArrayList
     118: dup
     119: aload_3
     120: bipush        10
     122: invokestatic  #137                // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     125: invokespecial #80                 // Method java/util/ArrayList."<init>":(I)V
     128: checkcast     #118                // class java/util/Collection
     131: astore        6
     133: iconst_0
     134: istore        7
     136: aload         5
     138: invokeinterface #28,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     143: astore        8
     145: aload         8
     147: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     152: ifeq          366
     155: aload         8
     157: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     162: astore        9
     164: aload         6
     166: aload         9
     168: checkcast     #40                 // class java/lang/String
     171: astore        10
     173: astore        24
     175: iconst_0
     176: istore        11
     178: aload         10
     180: astore        12
     182: new           #265                // class kotlin/ranges/IntRange
     185: dup
     186: iconst_1
     187: aload         10
     189: invokevirtual #268                // Method java/lang/String.length:()I
     192: invokespecial #271                // Method kotlin/ranges/IntRange."<init>":(II)V
     195: checkcast     #273                // class kotlin/ranges/IntProgression
     198: iconst_4
     199: invokestatic  #279                // Method kotlin/ranges/RangesKt.step:(Lkotlin/ranges/IntProgression;I)Lkotlin/ranges/IntProgression;
     202: checkcast     #24                 // class java/lang/Iterable
     205: astore        13
     207: aload         12
     209: checkcast     #42                 // class java/lang/CharSequence
     212: aload         13
     214: invokestatic  #283                // Method kotlin/text/StringsKt.slice:(Ljava/lang/CharSequence;Ljava/lang/Iterable;)Ljava/lang/CharSequence;
     217: invokevirtual #52                 // Method java/lang/Object.toString:()Ljava/lang/String;
     220: checkcast     #42                 // class java/lang/CharSequence
     223: astore        12
     225: nop
     226: iconst_0
     227: istore        13
     229: aload         12
     231: astore        14
     233: new           #77                 // class java/util/ArrayList
     236: dup
     237: aload         12
     239: invokeinterface #284,  1          // InterfaceMethod java/lang/CharSequence.length:()I
     244: invokespecial #80                 // Method java/util/ArrayList."<init>":(I)V
     247: checkcast     #118                // class java/util/Collection
     250: astore        15
     252: iconst_0
     253: istore        16
     255: iconst_0
     256: istore        17
     258: iconst_0
     259: istore        18
     261: iload         18
     263: aload         14
     265: invokeinterface #284,  1          // InterfaceMethod java/lang/CharSequence.length:()I
     270: if_icmpge     347
     273: aload         14
     275: iload         18
     277: invokeinterface #288,  2          // InterfaceMethod java/lang/CharSequence.charAt:(I)C
     282: istore        19
     284: aload         15
     286: iload         17
     288: iinc          17, 1
     291: iload         19
     293: istore        20
     295: istore        21
     297: astore        22
     299: iconst_0
     300: istore        23
     302: iload         20
     304: invokestatic  #292                // Method java/lang/Character.isLetter:(C)Z
     307: ifeq          329
     310: aload_2
     311: iload         21
     313: invokeinterface #116,  2          // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     318: checkcast     #82                 // class kotlin/collections/ArrayDeque
     321: iload         20
     323: invokestatic  #150                // Method java/lang/Character.valueOf:(C)Ljava/lang/Character;
     326: invokevirtual #295                // Method kotlin/collections/ArrayDeque.addLast:(Ljava/lang/Object;)V
     329: nop
     330: aload         22
     332: getstatic     #301                // Field kotlin/Unit.INSTANCE:Lkotlin/Unit;
     335: invokeinterface #151,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     340: pop
     341: iinc          18, 1
     344: goto          261
     347: aload         15
     349: checkcast     #89                 // class java/util/List
     352: nop
     353: nop
     354: aload         24
     356: swap
     357: invokeinterface #151,  2          // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     362: pop
     363: goto          145
     366: aload         6
     368: checkcast     #89                 // class java/util/List
     371: nop
     372: pop
     373: return
}


class Day003 {
    fun part1(input: List<String>): Int {
        var prioritiesSum = 0
        for (rucksack in input) {
            val firstHalf = rucksack.subSequence(0, rucksack.length / 2)
            val lastHalf = rucksack.subSequence(rucksack.length / 2, rucksack.length)
            for (char in lastHalf) {
                if (firstHalf.contains(char)) {
                    val itemPriority = if (char.isLowerCase()) char.code - 96 else char.code - 38
                    prioritiesSum += itemPriority
                    break
                }
            }
        }
        return prioritiesSum
    }

    fun part2(input: List<String>): Int {
        val chunkedInput = input.chunked(3)
        var prioritiesSum = 0
        for (chunk in chunkedInput) {
            for (char in chunk[0]) {
                if (chunk[1].contains(char) && chunk[2].contains(char)) {
                    val itemPriority = if (char.isLowerCase()) char.code - 96 else char.code - 38
                    prioritiesSum += itemPriority
                    break
                }
            }
        }
        return prioritiesSum

        // check out zipWithNext() for this solution
        // and intersect() method
        // single() to return one value
    }
}

Compiled from "Day003.kt"
public final class Day003 {
  public Day003();
    Code:
       0: aload_0
       1: invokespecial #8                  // Method java/lang/Object."<init>":()V
       4: return

  public final int part1(java.util.List<java.lang.String>);
    Code:
       0: aload_1
       1: ldc           #16                 // String input
       3: invokestatic  #22                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: iconst_0
       7: istore_2
       8: aload_1
       9: invokeinterface #28,  1           // InterfaceMethod java/util/List.iterator:()Ljava/util/Iterator;
      14: astore_3
      15: aload_3
      16: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      21: ifeq          145
      24: aload_3
      25: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      30: checkcast     #40                 // class java/lang/String
      33: astore        4
      35: aload         4
      37: iconst_0
      38: aload         4
      40: invokevirtual #44                 // Method java/lang/String.length:()I
      43: iconst_2
      44: idiv
      45: invokevirtual #48                 // Method java/lang/String.subSequence:(II)Ljava/lang/CharSequence;
      48: astore        5
      50: aload         4
      52: aload         4
      54: invokevirtual #44                 // Method java/lang/String.length:()I
      57: iconst_2
      58: idiv
      59: aload         4
      61: invokevirtual #44                 // Method java/lang/String.length:()I
      64: invokevirtual #48                 // Method java/lang/String.subSequence:(II)Ljava/lang/CharSequence;
      67: astore        6
      69: iconst_0
      70: istore        7
      72: iload         7
      74: aload         6
      76: invokeinterface #51,  1           // InterfaceMethod java/lang/CharSequence.length:()I
      81: if_icmpge     15
      84: aload         6
      86: iload         7
      88: invokeinterface #55,  2           // InterfaceMethod java/lang/CharSequence.charAt:(I)C
      93: istore        8
      95: aload         5
      97: iload         8
      99: iconst_0
     100: iconst_2
     101: aconst_null
     102: invokestatic  #61                 // Method kotlin/text/StringsKt.contains$default:(Ljava/lang/CharSequence;CZILjava/lang/Object;)Z
     105: ifeq          139
     108: iload         8
     110: invokestatic  #67                 // Method java/lang/Character.isLowerCase:(C)Z
     113: ifeq          124
     116: iload         8
     118: bipush        96
     120: isub
     121: goto          129
     124: iload         8
     126: bipush        38
     128: isub
     129: istore        9
     131: iload_2
     132: iload         9
     134: iadd
     135: istore_2
     136: goto          15
     139: iinc          7, 1
     142: goto          72
     145: iload_2
     146: ireturn

  public final int part2(java.util.List<java.lang.String>);
    Code:
       0: aload_1
       1: ldc           #16                 // String input
       3: invokestatic  #22                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: checkcast     #81                 // class java/lang/Iterable
      10: iconst_3
      11: invokestatic  #87                 // Method kotlin/collections/CollectionsKt.chunked:(Ljava/lang/Iterable;I)Ljava/util/List;
      14: astore_2
      15: iconst_0
      16: istore_3
      17: aload_2
      18: invokeinterface #28,  1           // InterfaceMethod java/util/List.iterator:()Ljava/util/Iterator;
      23: astore        4
      25: aload         4
      27: invokeinterface #34,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      32: ifeq          167
      35: aload         4
      37: invokeinterface #38,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      42: checkcast     #24                 // class java/util/List
      45: astore        5
      47: aload         5
      49: iconst_0
      50: invokeinterface #91,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      55: checkcast     #40                 // class java/lang/String
      58: astore        6
      60: iconst_0
      61: istore        7
      63: aload         6
      65: invokevirtual #44                 // Method java/lang/String.length:()I
      68: istore        8
      70: iload         7
      72: iload         8
      74: if_icmpge     25
      77: aload         6
      79: iload         7
      81: invokevirtual #92                 // Method java/lang/String.charAt:(I)C
      84: istore        9
      86: aload         5
      88: iconst_1
      89: invokeinterface #91,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      94: checkcast     #50                 // class java/lang/CharSequence
      97: iload         9
      99: iconst_0
     100: iconst_2
     101: aconst_null
     102: invokestatic  #61                 // Method kotlin/text/StringsKt.contains$default:(Ljava/lang/CharSequence;CZILjava/lang/Object;)Z
     105: ifeq          161
     108: aload         5
     110: iconst_2
     111: invokeinterface #91,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     116: checkcast     #50                 // class java/lang/CharSequence
     119: iload         9
     121: iconst_0
     122: iconst_2
     123: aconst_null
     124: invokestatic  #61                 // Method kotlin/text/StringsKt.contains$default:(Ljava/lang/CharSequence;CZILjava/lang/Object;)Z
     127: ifeq          161
     130: iload         9
     132: invokestatic  #67                 // Method java/lang/Character.isLowerCase:(C)Z
     135: ifeq          146
     138: iload         9
     140: bipush        96
     142: isub
     143: goto          151
     146: iload         9
     148: bipush        38
     150: isub
     151: istore        10
     153: iload_3
     154: iload         10
     156: iadd
     157: istore_3
     158: goto          25
     161: iinc          7, 1
     164: goto          70
     167: iload_3
     168: ireturn
}


class Day004 {

    var counter = 0

    fun part1(elfPairs: List<List<String>>): Int {
        for (elfPair in elfPairs) {
            val firstElf = elfPair[0].split('-').map { it.toInt() }
            val secondElf = elfPair[1].split('-').map { it.toInt() }
            countContainingRanges(firstElf, secondElf)
        }
        return counter
    }

    fun part1Functional(elfPairs: List<List<String>>): Int {
        elfPairs.forEach { elfPair ->
            val firstElf = elfPair[0].split('-').map { it.toInt() }
            val secondElf = elfPair[1].split('-').map { it.toInt() }
            countContainingRanges(firstElf, secondElf)
        }
        return counter
    }

    private fun countContainingRanges(firstElf: List<Int>, secondElf: List<Int>) {
        if ((firstElf[0] >= secondElf[0] && firstElf[1] <= secondElf[1]) ||
            (secondElf[0] >= firstElf[0] && secondElf[1] <= firstElf[1])
        ) {
            counter++
        }
    }

    fun part2(elfPairs: List<List<String>>): Int {
        for (elfPair in elfPairs) {
            val firstElf = elfPair[0].split('-').map { it.toInt() }
            val secondElf = elfPair[1].split('-').map { it.toInt() }
            if ((firstElf[1] >= secondElf[0] && firstElf[1] <= secondElf[1]) ||
                (secondElf[1] >= firstElf[0] && secondElf[1] <= firstElf[1])
            ) {
                counter++
            }
        }
        return counter
    }

    fun test() {
        val pair = Pair("primu", "ultimu")
        pair.first
    }

    // transform to Pair<IntRange, IntRange> -> you can use first and last in an IntRange
    // substringBefore() method also useful
    // .count() -> how many of the items in the set match the predicate
    // https://todd.ginsberg.com/post/advent-of-code/2022/day4/
}

Compiled from "Day004.kt"
public final class Day004 {
  private int counter;

  public Day004();
    Code:
       0: aload_0
       1: invokespecial #8                  // Method java/lang/Object."<init>":()V
       4: return

  public final int getCounter();
    Code:
       0: aload_0
       1: getfield      #16                 // Field counter:I
       4: ireturn

  public final void setCounter(int);
    Code:
       0: aload_0
       1: iload_1
       2: putfield      #16                 // Field counter:I
       5: return

  public final int part1(java.util.List<? extends java.util.List<java.lang.String>>);
    Code:
       0: aload_1
       1: ldc           #25                 // String elfPairs
       3: invokestatic  #31                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: invokeinterface #37,  1           // InterfaceMethod java/util/List.iterator:()Ljava/util/Iterator;
      12: astore_2
      13: aload_2
      14: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      19: ifeq          315
      22: aload_2
      23: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      28: checkcast     #33                 // class java/util/List
      31: astore_3
      32: aload_3
      33: iconst_0
      34: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      39: checkcast     #53                 // class java/lang/CharSequence
      42: iconst_1
      43: newarray       char
      45: astore        5
      47: aload         5
      49: iconst_0
      50: bipush        45
      52: castore
      53: aload         5
      55: iconst_0
      56: iconst_0
      57: bipush        6
      59: aconst_null
      60: invokestatic  #59                 // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[CZIILjava/lang/Object;)Ljava/util/List;
      63: checkcast     #61                 // class java/lang/Iterable
      66: astore        5
      68: iconst_0
      69: istore        6
      71: aload         5
      73: astore        7
      75: new           #63                 // class java/util/ArrayList
      78: dup
      79: aload         5
      81: bipush        10
      83: invokestatic  #69                 // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      86: invokespecial #71                 // Method java/util/ArrayList."<init>":(I)V
      89: checkcast     #73                 // class java/util/Collection
      92: astore        8
      94: iconst_0
      95: istore        9
      97: aload         7
      99: invokeinterface #74,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     104: astore        10
     106: aload         10
     108: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     113: ifeq          160
     116: aload         10
     118: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     123: astore        11
     125: aload         8
     127: aload         11
     129: checkcast     #76                 // class java/lang/String
     132: astore        12
     134: astore        15
     136: iconst_0
     137: istore        13
     139: aload         12
     141: invokestatic  #82                 // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     144: nop
     145: invokestatic  #86                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     148: aload         15
     150: swap
     151: invokeinterface #90,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     156: pop
     157: goto          106
     160: aload         8
     162: checkcast     #33                 // class java/util/List
     165: nop
     166: astore        4
     168: aload_3
     169: iconst_1
     170: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     175: checkcast     #53                 // class java/lang/CharSequence
     178: iconst_1
     179: newarray       char
     181: astore        6
     183: aload         6
     185: iconst_0
     186: bipush        45
     188: castore
     189: aload         6
     191: iconst_0
     192: iconst_0
     193: bipush        6
     195: aconst_null
     196: invokestatic  #59                 // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[CZIILjava/lang/Object;)Ljava/util/List;
     199: checkcast     #61                 // class java/lang/Iterable
     202: astore        6
     204: iconst_0
     205: istore        7
     207: aload         6
     209: astore        8
     211: new           #63                 // class java/util/ArrayList
     214: dup
     215: aload         6
     217: bipush        10
     219: invokestatic  #69                 // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     222: invokespecial #71                 // Method java/util/ArrayList."<init>":(I)V
     225: checkcast     #73                 // class java/util/Collection
     228: astore        9
     230: iconst_0
     231: istore        10
     233: aload         8
     235: invokeinterface #74,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     240: astore        11
     242: aload         11
     244: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     249: ifeq          296
     252: aload         11
     254: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     259: astore        12
     261: aload         9
     263: aload         12
     265: checkcast     #76                 // class java/lang/String
     268: astore        13
     270: astore        15
     272: iconst_0
     273: istore        14
     275: aload         13
     277: invokestatic  #82                 // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     280: nop
     281: invokestatic  #86                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     284: aload         15
     286: swap
     287: invokeinterface #90,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     292: pop
     293: goto          242
     296: aload         9
     298: checkcast     #33                 // class java/util/List
     301: nop
     302: astore        5
     304: aload_0
     305: aload         4
     307: aload         5
     309: invokespecial #94                 // Method countContainingRanges:(Ljava/util/List;Ljava/util/List;)V
     312: goto          13
     315: aload_0
     316: getfield      #16                 // Field counter:I
     319: ireturn

  public final int part1Functional(java.util.List<? extends java.util.List<java.lang.String>>);
    Code:
       0: aload_1
       1: ldc           #25                 // String elfPairs
       3: invokestatic  #31                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: checkcast     #61                 // class java/lang/Iterable
      10: astore_2
      11: iconst_0
      12: istore_3
      13: aload_2
      14: invokeinterface #74,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
      19: astore        4
      21: aload         4
      23: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      28: ifeq          337
      31: aload         4
      33: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      38: astore        5
      40: aload         5
      42: checkcast     #33                 // class java/util/List
      45: astore        6
      47: iconst_0
      48: istore        7
      50: aload         6
      52: iconst_0
      53: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      58: checkcast     #53                 // class java/lang/CharSequence
      61: iconst_1
      62: newarray       char
      64: astore        8
      66: aload         8
      68: iconst_0
      69: bipush        45
      71: castore
      72: aload         8
      74: iconst_0
      75: iconst_0
      76: bipush        6
      78: aconst_null
      79: invokestatic  #59                 // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[CZIILjava/lang/Object;)Ljava/util/List;
      82: checkcast     #61                 // class java/lang/Iterable
      85: astore        8
      87: iconst_0
      88: istore        9
      90: aload         8
      92: astore        10
      94: new           #63                 // class java/util/ArrayList
      97: dup
      98: aload         8
     100: bipush        10
     102: invokestatic  #69                 // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     105: invokespecial #71                 // Method java/util/ArrayList."<init>":(I)V
     108: checkcast     #73                 // class java/util/Collection
     111: astore        11
     113: iconst_0
     114: istore        12
     116: aload         10
     118: invokeinterface #74,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     123: astore        13
     125: aload         13
     127: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     132: ifeq          179
     135: aload         13
     137: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     142: astore        14
     144: aload         11
     146: aload         14
     148: checkcast     #76                 // class java/lang/String
     151: astore        15
     153: astore        16
     155: iconst_0
     156: istore        17
     158: aload         15
     160: invokestatic  #82                 // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     163: nop
     164: invokestatic  #86                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     167: aload         16
     169: swap
     170: invokeinterface #90,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     175: pop
     176: goto          125
     179: aload         11
     181: checkcast     #33                 // class java/util/List
     184: nop
     185: astore        18
     187: aload         6
     189: iconst_1
     190: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     195: checkcast     #53                 // class java/lang/CharSequence
     198: iconst_1
     199: newarray       char
     201: astore        9
     203: aload         9
     205: iconst_0
     206: bipush        45
     208: castore
     209: aload         9
     211: iconst_0
     212: iconst_0
     213: bipush        6
     215: aconst_null
     216: invokestatic  #59                 // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[CZIILjava/lang/Object;)Ljava/util/List;
     219: checkcast     #61                 // class java/lang/Iterable
     222: astore        9
     224: iconst_0
     225: istore        10
     227: aload         9
     229: astore        11
     231: new           #63                 // class java/util/ArrayList
     234: dup
     235: aload         9
     237: bipush        10
     239: invokestatic  #69                 // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     242: invokespecial #71                 // Method java/util/ArrayList."<init>":(I)V
     245: checkcast     #73                 // class java/util/Collection
     248: astore        12
     250: iconst_0
     251: istore        13
     253: aload         11
     255: invokeinterface #74,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     260: astore        14
     262: aload         14
     264: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     269: ifeq          316
     272: aload         14
     274: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     279: astore        15
     281: aload         12
     283: aload         15
     285: checkcast     #76                 // class java/lang/String
     288: astore        17
     290: astore        16
     292: iconst_0
     293: istore        19
     295: aload         17
     297: invokestatic  #82                 // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     300: nop
     301: invokestatic  #86                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     304: aload         16
     306: swap
     307: invokeinterface #90,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     312: pop
     313: goto          262
     316: aload         12
     318: checkcast     #33                 // class java/util/List
     321: nop
     322: astore        8
     324: aload_0
     325: aload         18
     327: aload         8
     329: invokespecial #94                 // Method countContainingRanges:(Ljava/util/List;Ljava/util/List;)V
     332: nop
     333: nop
     334: goto          21
     337: nop
     338: aload_0
     339: getfield      #16                 // Field counter:I
     342: ireturn

  private final void countContainingRanges(java.util.List<java.lang.Integer>, java.util.List<java.lang.Integer>);
    Code:
       0: aload_1
       1: iconst_0
       2: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
       7: checkcast     #121                // class java/lang/Number
      10: invokevirtual #124                // Method java/lang/Number.intValue:()I
      13: aload_2
      14: iconst_0
      15: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      20: checkcast     #121                // class java/lang/Number
      23: invokevirtual #124                // Method java/lang/Number.intValue:()I
      26: if_icmplt     58
      29: aload_1
      30: iconst_1
      31: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      36: checkcast     #121                // class java/lang/Number
      39: invokevirtual #124                // Method java/lang/Number.intValue:()I
      42: aload_2
      43: iconst_1
      44: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      49: checkcast     #121                // class java/lang/Number
      52: invokevirtual #124                // Method java/lang/Number.intValue:()I
      55: if_icmple     116
      58: aload_2
      59: iconst_0
      60: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      65: checkcast     #121                // class java/lang/Number
      68: invokevirtual #124                // Method java/lang/Number.intValue:()I
      71: aload_1
      72: iconst_0
      73: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      78: checkcast     #121                // class java/lang/Number
      81: invokevirtual #124                // Method java/lang/Number.intValue:()I
      84: if_icmplt     128
      87: aload_2
      88: iconst_1
      89: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      94: checkcast     #121                // class java/lang/Number
      97: invokevirtual #124                // Method java/lang/Number.intValue:()I
     100: aload_1
     101: iconst_1
     102: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     107: checkcast     #121                // class java/lang/Number
     110: invokevirtual #124                // Method java/lang/Number.intValue:()I
     113: if_icmpgt     128
     116: aload_0
     117: getfield      #16                 // Field counter:I
     120: istore_3
     121: aload_0
     122: iload_3
     123: iconst_1
     124: iadd
     125: putfield      #16                 // Field counter:I
     128: return

  public final int part2(java.util.List<? extends java.util.List<java.lang.String>>);
    Code:
       0: aload_1
       1: ldc           #25                 // String elfPairs
       3: invokestatic  #31                 // Method kotlin/jvm/internal/Intrinsics.checkNotNullParameter:(Ljava/lang/Object;Ljava/lang/String;)V
       6: aload_1
       7: invokeinterface #37,  1           // InterfaceMethod java/util/List.iterator:()Ljava/util/Iterator;
      12: astore_2
      13: aload_2
      14: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
      19: ifeq          445
      22: aload_2
      23: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
      28: checkcast     #33                 // class java/util/List
      31: astore_3
      32: aload_3
      33: iconst_0
      34: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
      39: checkcast     #53                 // class java/lang/CharSequence
      42: iconst_1
      43: newarray       char
      45: astore        5
      47: aload         5
      49: iconst_0
      50: bipush        45
      52: castore
      53: aload         5
      55: iconst_0
      56: iconst_0
      57: bipush        6
      59: aconst_null
      60: invokestatic  #59                 // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[CZIILjava/lang/Object;)Ljava/util/List;
      63: checkcast     #61                 // class java/lang/Iterable
      66: astore        5
      68: iconst_0
      69: istore        6
      71: aload         5
      73: astore        7
      75: new           #63                 // class java/util/ArrayList
      78: dup
      79: aload         5
      81: bipush        10
      83: invokestatic  #69                 // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
      86: invokespecial #71                 // Method java/util/ArrayList."<init>":(I)V
      89: checkcast     #73                 // class java/util/Collection
      92: astore        8
      94: iconst_0
      95: istore        9
      97: aload         7
      99: invokeinterface #74,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     104: astore        10
     106: aload         10
     108: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     113: ifeq          160
     116: aload         10
     118: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     123: astore        11
     125: aload         8
     127: aload         11
     129: checkcast     #76                 // class java/lang/String
     132: astore        12
     134: astore        15
     136: iconst_0
     137: istore        13
     139: aload         12
     141: invokestatic  #82                 // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     144: nop
     145: invokestatic  #86                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     148: aload         15
     150: swap
     151: invokeinterface #90,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     156: pop
     157: goto          106
     160: aload         8
     162: checkcast     #33                 // class java/util/List
     165: nop
     166: astore        4
     168: aload_3
     169: iconst_1
     170: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     175: checkcast     #53                 // class java/lang/CharSequence
     178: iconst_1
     179: newarray       char
     181: astore        6
     183: aload         6
     185: iconst_0
     186: bipush        45
     188: castore
     189: aload         6
     191: iconst_0
     192: iconst_0
     193: bipush        6
     195: aconst_null
     196: invokestatic  #59                 // Method kotlin/text/StringsKt.split$default:(Ljava/lang/CharSequence;[CZIILjava/lang/Object;)Ljava/util/List;
     199: checkcast     #61                 // class java/lang/Iterable
     202: astore        6
     204: iconst_0
     205: istore        7
     207: aload         6
     209: astore        8
     211: new           #63                 // class java/util/ArrayList
     214: dup
     215: aload         6
     217: bipush        10
     219: invokestatic  #69                 // Method kotlin/collections/CollectionsKt.collectionSizeOrDefault:(Ljava/lang/Iterable;I)I
     222: invokespecial #71                 // Method java/util/ArrayList."<init>":(I)V
     225: checkcast     #73                 // class java/util/Collection
     228: astore        9
     230: iconst_0
     231: istore        10
     233: aload         8
     235: invokeinterface #74,  1           // InterfaceMethod java/lang/Iterable.iterator:()Ljava/util/Iterator;
     240: astore        11
     242: aload         11
     244: invokeinterface #43,  1           // InterfaceMethod java/util/Iterator.hasNext:()Z
     249: ifeq          296
     252: aload         11
     254: invokeinterface #47,  1           // InterfaceMethod java/util/Iterator.next:()Ljava/lang/Object;
     259: astore        12
     261: aload         9
     263: aload         12
     265: checkcast     #76                 // class java/lang/String
     268: astore        13
     270: astore        15
     272: iconst_0
     273: istore        14
     275: aload         13
     277: invokestatic  #82                 // Method java/lang/Integer.parseInt:(Ljava/lang/String;)I
     280: nop
     281: invokestatic  #86                 // Method java/lang/Integer.valueOf:(I)Ljava/lang/Integer;
     284: aload         15
     286: swap
     287: invokeinterface #90,  2           // InterfaceMethod java/util/Collection.add:(Ljava/lang/Object;)Z
     292: pop
     293: goto          242
     296: aload         9
     298: checkcast     #33                 // class java/util/List
     301: nop
     302: astore        5
     304: aload         4
     306: iconst_1
     307: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     312: checkcast     #121                // class java/lang/Number
     315: invokevirtual #124                // Method java/lang/Number.intValue:()I
     318: aload         5
     320: iconst_0
     321: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     326: checkcast     #121                // class java/lang/Number
     329: invokevirtual #124                // Method java/lang/Number.intValue:()I
     332: if_icmplt     366
     335: aload         4
     337: iconst_1
     338: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     343: checkcast     #121                // class java/lang/Number
     346: invokevirtual #124                // Method java/lang/Number.intValue:()I
     349: aload         5
     351: iconst_1
     352: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     357: checkcast     #121                // class java/lang/Number
     360: invokevirtual #124                // Method java/lang/Number.intValue:()I
     363: if_icmple     428
     366: aload         5
     368: iconst_1
     369: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     374: checkcast     #121                // class java/lang/Number
     377: invokevirtual #124                // Method java/lang/Number.intValue:()I
     380: aload         4
     382: iconst_0
     383: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     388: checkcast     #121                // class java/lang/Number
     391: invokevirtual #124                // Method java/lang/Number.intValue:()I
     394: if_icmplt     13
     397: aload         5
     399: iconst_1
     400: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     405: checkcast     #121                // class java/lang/Number
     408: invokevirtual #124                // Method java/lang/Number.intValue:()I
     411: aload         4
     413: iconst_1
     414: invokeinterface #51,  2           // InterfaceMethod java/util/List.get:(I)Ljava/lang/Object;
     419: checkcast     #121                // class java/lang/Number
     422: invokevirtual #124                // Method java/lang/Number.intValue:()I
     425: if_icmpgt     13
     428: aload_0
     429: getfield      #16                 // Field counter:I
     432: istore        6
     434: aload_0
     435: iload         6
     437: iconst_1
     438: iadd
     439: putfield      #16                 // Field counter:I
     442: goto          13
     445: aload_0
     446: getfield      #16                 // Field counter:I
     449: ireturn

  public final void test();
    Code:
       0: new           #130                // class kotlin/Pair
       3: dup
       4: ldc           #132                // String primu
       6: ldc           #134                // String ultimu
       8: invokespecial #137                // Method kotlin/Pair."<init>":(Ljava/lang/Object;Ljava/lang/Object;)V
      11: astore_1
      12: aload_1
      13: invokevirtual #140                // Method kotlin/Pair.getFirst:()Ljava/lang/Object;
      16: pop
      17: return
}