support multiple stages for each level, resetting the machine between

This commit is contained in:
Crispy 2024-12-18 21:31:05 +01:00
parent e6437ae9cf
commit 43130b665d
17 changed files with 220 additions and 126 deletions

View file

@ -3,7 +3,8 @@
"sort_order": 23,
"name": "Fives",
"description": "count how many fives are in the input",
"init_board": null,
"inputs": [182, 236, 71, 5, 5, 242, 29, 99, 19, 230, 217, 5, 67, 5, 223, 224, 70, 243, 3, 74, 242, 5, 171, 31, 96, 5, 169, 70, 5, 163, 72, 5, 172, 148, 5, 208, 28, 220, 17, 184, 172, 238, 5, 105, 119, 5, 106, 100, 73, 53, 42, 221, 155, 5, 74, 100, 161, 36, 16, 239, 193, 164, 64, 162, 222, 155, 107, 14, 45, 52, 159, 31, 199, 124, 129, 0],
"outputs": [12]
"stages": [{
"input": [182, 236, 71, 5, 5, 242, 29, 99, 19, 230, 217, 5, 67, 5, 223, 224, 70, 243, 3, 74, 242, 5, 171, 31, 96, 5, 169, 70, 5, 163, 72, 5, 172, 148, 5, 208, 28, 220, 17, 184, 172, 238, 5, 105, 119, 5, 106, 100, 73, 53, 42, 221, 155, 5, 74, 100, 161, 36, 16, 239, 193, 164, 64, 162, 222, 155, 107, 14, 45, 52, 159, 31, 199, 124, 129, 0],
"output": [12]
}]
}

View file

@ -3,7 +3,8 @@
"sort_order": 22,
"name": "Length",
"description": "count how many numbers are in the input, until the first zero",
"init_board": null,
"inputs": [182, 236, 71, 5, 5, 242, 29, 99, 19, 230, 217, 5, 67, 5, 223, 224, 70, 243, 3, 74, 242, 5, 171, 31, 96, 5, 169, 70, 5, 163, 72, 5, 172, 148, 5, 208, 28, 220, 17, 184, 172, 0],
"outputs": [41]
"stages": [{
"input": [182, 236, 71, 5, 5, 242, 29, 99, 19, 230, 217, 5, 67, 5, 223, 224, 70, 243, 3, 74, 242, 5, 171, 31, 96, 5, 169, 70, 5, 163, 72, 5, 172, 148, 5, 208, 28, 220, 17, 184, 172, 0],
"output": [41]
}]
}

View file

@ -3,7 +3,8 @@
"sort_order": 21,
"name": "Null Separation",
"description": "output everything after the first zero in the input data",
"init_board": null,
"inputs": "9834726\u0000Hello, worlg!",
"outputs": "Hello, worlg!"
"stages": [{
"input": "9834726\u0000Hello, worlg!",
"output": "Hello, worlg!"
}]
}

View file

@ -3,7 +3,8 @@
"sort_order": 24,
"name": "Reverse",
"description": "read input until zero and output the same thing in reverse",
"init_board": null,
"inputs": "tnropmi yrev\u0000",
"outputs": "very impornt"
"stages": [{
"input": "tnropmi yrev\u0000",
"output": "very impornt"
}]
}