Compare commits
69 commits
main
...
4cbcb7e0c2
Author | SHA1 | Date | |
---|---|---|---|
4cbcb7e0c2 | |||
8e1fcf87c4 | |||
82e362ecdf | |||
475d40bf90 | |||
6c1a8a5699 | |||
372fde8d69 | |||
3dd4b45eba | |||
8bde0a6ce9 | |||
b8d9eb70ac | |||
f84d404eb9 | |||
5bf3f4e0ce | |||
873ea19b8d | |||
6dee5caf29 | |||
477f518531 | |||
499c02756e | |||
1295c5f720 | |||
fbc4917943 | |||
f14cd294c2 | |||
7c5dc39073 | |||
29a768fdf8 | |||
0f3334d99f | |||
32f676dcd7 | |||
c40425cb4e | |||
cb5372410c | |||
d52596530a | |||
df0aa288c5 | |||
7997b49c61 | |||
097a2dc025 | |||
d9fcfcba9f | |||
6935837ed2 | |||
bad4db3946 | |||
73dc7182c7 | |||
826de9381d | |||
5b1515f6ee | |||
9b12fb9d02 | |||
3566e499b6 | |||
52465a9380 | |||
f717860fe3 | |||
f8f2470b12 | |||
c5eb7888ac | |||
553d79f66c | |||
86d6c4a80f | |||
f989d052be | |||
6bcb64280d | |||
58ab8238f8 | |||
d6f5591e66 | |||
8a359603d5 | |||
9aefab8549 | |||
51aaea90dc | |||
98c1af4d58 | |||
b88afd44e0 | |||
38cac26cb7 | |||
8bb03a8dcd | |||
9331250c28 | |||
23e5f473c0 | |||
e8f88e8b3c | |||
793eefc817 | |||
eecf2c2f35 | |||
4ec5908454 | |||
e76f855d05 | |||
cdfec86112 | |||
377e7d3e57 | |||
7ae2f5a4af | |||
1b2695c305 | |||
a34a10b15e | |||
066513b45a | |||
feda46249b | |||
03abb1a5ae | |||
b4004fd75f |
216 changed files with 210 additions and 132183 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -1,4 +1 @@
|
|||
example*
|
||||
*.hi
|
||||
*.o
|
||||
target/
|
||||
|
|
3
2020/.gitignore
vendored
Normal file
3
2020/.gitignore
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
example*
|
||||
*.hi
|
||||
*.o
|
|
@ -1,2 +0,0 @@
|
|||
820
|
||||
???
|
|
@ -1,747 +0,0 @@
|
|||
S2
|
||||
W4
|
||||
F31
|
||||
N2
|
||||
E4
|
||||
F98
|
||||
R180
|
||||
W2
|
||||
N4
|
||||
E1
|
||||
L180
|
||||
W2
|
||||
S5
|
||||
F69
|
||||
W5
|
||||
F12
|
||||
E3
|
||||
F91
|
||||
R90
|
||||
E1
|
||||
L90
|
||||
F73
|
||||
W4
|
||||
N3
|
||||
R90
|
||||
F76
|
||||
R90
|
||||
F33
|
||||
W2
|
||||
L90
|
||||
F51
|
||||
E1
|
||||
S3
|
||||
L180
|
||||
F62
|
||||
N5
|
||||
L180
|
||||
N3
|
||||
E1
|
||||
L90
|
||||
F83
|
||||
R180
|
||||
W4
|
||||
F29
|
||||
E2
|
||||
L90
|
||||
L90
|
||||
N3
|
||||
W1
|
||||
S1
|
||||
E2
|
||||
L270
|
||||
L180
|
||||
N2
|
||||
E1
|
||||
F77
|
||||
N2
|
||||
F11
|
||||
L180
|
||||
E2
|
||||
F45
|
||||
N4
|
||||
W5
|
||||
S2
|
||||
L90
|
||||
N2
|
||||
F14
|
||||
L90
|
||||
W3
|
||||
F6
|
||||
N5
|
||||
E2
|
||||
R90
|
||||
E2
|
||||
L90
|
||||
F39
|
||||
L90
|
||||
F45
|
||||
W2
|
||||
F67
|
||||
W4
|
||||
F50
|
||||
E1
|
||||
F92
|
||||
W5
|
||||
F75
|
||||
N2
|
||||
W1
|
||||
S3
|
||||
R90
|
||||
W5
|
||||
F51
|
||||
L90
|
||||
E3
|
||||
F71
|
||||
N3
|
||||
E3
|
||||
F74
|
||||
E4
|
||||
S3
|
||||
W2
|
||||
L180
|
||||
E2
|
||||
S5
|
||||
L270
|
||||
R90
|
||||
N2
|
||||
R90
|
||||
E4
|
||||
L270
|
||||
S5
|
||||
E4
|
||||
W3
|
||||
L90
|
||||
N2
|
||||
F32
|
||||
E3
|
||||
N5
|
||||
E2
|
||||
R180
|
||||
F27
|
||||
S1
|
||||
R90
|
||||
F94
|
||||
E2
|
||||
F82
|
||||
N3
|
||||
L90
|
||||
F100
|
||||
W4
|
||||
L90
|
||||
S1
|
||||
E4
|
||||
F26
|
||||
R90
|
||||
R90
|
||||
F12
|
||||
W4
|
||||
F70
|
||||
L90
|
||||
F100
|
||||
W4
|
||||
S2
|
||||
R90
|
||||
E3
|
||||
F11
|
||||
L90
|
||||
F32
|
||||
L180
|
||||
S2
|
||||
F11
|
||||
S2
|
||||
L90
|
||||
S3
|
||||
E4
|
||||
F93
|
||||
S1
|
||||
R90
|
||||
S2
|
||||
F20
|
||||
E2
|
||||
F9
|
||||
S5
|
||||
F23
|
||||
E4
|
||||
S2
|
||||
F38
|
||||
L90
|
||||
N3
|
||||
F3
|
||||
E2
|
||||
F37
|
||||
N2
|
||||
F89
|
||||
E5
|
||||
F43
|
||||
R90
|
||||
F88
|
||||
N5
|
||||
F52
|
||||
W5
|
||||
F24
|
||||
E4
|
||||
L180
|
||||
S4
|
||||
E3
|
||||
F14
|
||||
L90
|
||||
S2
|
||||
E5
|
||||
L180
|
||||
N4
|
||||
F98
|
||||
N4
|
||||
W2
|
||||
S2
|
||||
W1
|
||||
S3
|
||||
R90
|
||||
F98
|
||||
E4
|
||||
R270
|
||||
E2
|
||||
F45
|
||||
L90
|
||||
F75
|
||||
R180
|
||||
W3
|
||||
L180
|
||||
F42
|
||||
E2
|
||||
N4
|
||||
L90
|
||||
F2
|
||||
R180
|
||||
W5
|
||||
E5
|
||||
N5
|
||||
R180
|
||||
F92
|
||||
L90
|
||||
F95
|
||||
E3
|
||||
F61
|
||||
S5
|
||||
E2
|
||||
L180
|
||||
E1
|
||||
E2
|
||||
F27
|
||||
S3
|
||||
W2
|
||||
S1
|
||||
F86
|
||||
R270
|
||||
S1
|
||||
L90
|
||||
R90
|
||||
E5
|
||||
S2
|
||||
S2
|
||||
F93
|
||||
E2
|
||||
R270
|
||||
N3
|
||||
W3
|
||||
F74
|
||||
R90
|
||||
F94
|
||||
E2
|
||||
F88
|
||||
S1
|
||||
R90
|
||||
W4
|
||||
L90
|
||||
N5
|
||||
F59
|
||||
R90
|
||||
N1
|
||||
F24
|
||||
S2
|
||||
F10
|
||||
L90
|
||||
F72
|
||||
L90
|
||||
F55
|
||||
N2
|
||||
E1
|
||||
R90
|
||||
N1
|
||||
E1
|
||||
F12
|
||||
L90
|
||||
S5
|
||||
E5
|
||||
F44
|
||||
L180
|
||||
S4
|
||||
E2
|
||||
E5
|
||||
S1
|
||||
E5
|
||||
R180
|
||||
S1
|
||||
R90
|
||||
N3
|
||||
L90
|
||||
E2
|
||||
S4
|
||||
L90
|
||||
R90
|
||||
W1
|
||||
R90
|
||||
E5
|
||||
N1
|
||||
L90
|
||||
N1
|
||||
E3
|
||||
S5
|
||||
W1
|
||||
S1
|
||||
L270
|
||||
E2
|
||||
E4
|
||||
F31
|
||||
S2
|
||||
E4
|
||||
N2
|
||||
W3
|
||||
L90
|
||||
F7
|
||||
S3
|
||||
F23
|
||||
S3
|
||||
E1
|
||||
F15
|
||||
S1
|
||||
L90
|
||||
E4
|
||||
S1
|
||||
L90
|
||||
N3
|
||||
W1
|
||||
F13
|
||||
R180
|
||||
S3
|
||||
F37
|
||||
N3
|
||||
W5
|
||||
S5
|
||||
L90
|
||||
F55
|
||||
F54
|
||||
R90
|
||||
E1
|
||||
N4
|
||||
F68
|
||||
S5
|
||||
F3
|
||||
L180
|
||||
F75
|
||||
N3
|
||||
R90
|
||||
W4
|
||||
F78
|
||||
S4
|
||||
S3
|
||||
R180
|
||||
N2
|
||||
R90
|
||||
N1
|
||||
F20
|
||||
L180
|
||||
F12
|
||||
S4
|
||||
E4
|
||||
L180
|
||||
F10
|
||||
E2
|
||||
N5
|
||||
E3
|
||||
F13
|
||||
E3
|
||||
L90
|
||||
F55
|
||||
E5
|
||||
F96
|
||||
W1
|
||||
F100
|
||||
R90
|
||||
F97
|
||||
W4
|
||||
W2
|
||||
N4
|
||||
W4
|
||||
N3
|
||||
E4
|
||||
R90
|
||||
S1
|
||||
W4
|
||||
F80
|
||||
W2
|
||||
L90
|
||||
F64
|
||||
W5
|
||||
S2
|
||||
W3
|
||||
R180
|
||||
W1
|
||||
S2
|
||||
F83
|
||||
R180
|
||||
F37
|
||||
W4
|
||||
N4
|
||||
F57
|
||||
E3
|
||||
R90
|
||||
F37
|
||||
S4
|
||||
R180
|
||||
F62
|
||||
R90
|
||||
S5
|
||||
F9
|
||||
E3
|
||||
N4
|
||||
L90
|
||||
W4
|
||||
R90
|
||||
F97
|
||||
W4
|
||||
R180
|
||||
F2
|
||||
W4
|
||||
S1
|
||||
F77
|
||||
L180
|
||||
R90
|
||||
E4
|
||||
F58
|
||||
S2
|
||||
L90
|
||||
E1
|
||||
N3
|
||||
L90
|
||||
N2
|
||||
W4
|
||||
N1
|
||||
L90
|
||||
F94
|
||||
E1
|
||||
R90
|
||||
F29
|
||||
S3
|
||||
L180
|
||||
E2
|
||||
R180
|
||||
S5
|
||||
F62
|
||||
L90
|
||||
N2
|
||||
R90
|
||||
E4
|
||||
F93
|
||||
L90
|
||||
E5
|
||||
N4
|
||||
L180
|
||||
N3
|
||||
F20
|
||||
R90
|
||||
E3
|
||||
L90
|
||||
S3
|
||||
F24
|
||||
E4
|
||||
R90
|
||||
E4
|
||||
F89
|
||||
N1
|
||||
F13
|
||||
R180
|
||||
W1
|
||||
L90
|
||||
S3
|
||||
W5
|
||||
S4
|
||||
L180
|
||||
W3
|
||||
F90
|
||||
S4
|
||||
E3
|
||||
F36
|
||||
S3
|
||||
E2
|
||||
F37
|
||||
E5
|
||||
F31
|
||||
L90
|
||||
F68
|
||||
S5
|
||||
F74
|
||||
L90
|
||||
F59
|
||||
R180
|
||||
F20
|
||||
N1
|
||||
L180
|
||||
N5
|
||||
L90
|
||||
E3
|
||||
N2
|
||||
W4
|
||||
F54
|
||||
L90
|
||||
F77
|
||||
R270
|
||||
S5
|
||||
F82
|
||||
R90
|
||||
E2
|
||||
L180
|
||||
F59
|
||||
R90
|
||||
E5
|
||||
R90
|
||||
F26
|
||||
E4
|
||||
F91
|
||||
R90
|
||||
W4
|
||||
F6
|
||||
W5
|
||||
F34
|
||||
S4
|
||||
F61
|
||||
W2
|
||||
S2
|
||||
R270
|
||||
F45
|
||||
R180
|
||||
N5
|
||||
L90
|
||||
F26
|
||||
L90
|
||||
R90
|
||||
S1
|
||||
W3
|
||||
N5
|
||||
W5
|
||||
L90
|
||||
N3
|
||||
L90
|
||||
N3
|
||||
E3
|
||||
L90
|
||||
F1
|
||||
E4
|
||||
L90
|
||||
F60
|
||||
N3
|
||||
F7
|
||||
S1
|
||||
E1
|
||||
F68
|
||||
L90
|
||||
N5
|
||||
E5
|
||||
F36
|
||||
W3
|
||||
S5
|
||||
L270
|
||||
N2
|
||||
E1
|
||||
R90
|
||||
F8
|
||||
S3
|
||||
E1
|
||||
R90
|
||||
N1
|
||||
E2
|
||||
R90
|
||||
N1
|
||||
F90
|
||||
E2
|
||||
F63
|
||||
S2
|
||||
F17
|
||||
S1
|
||||
E3
|
||||
L90
|
||||
E4
|
||||
L180
|
||||
N4
|
||||
W1
|
||||
S4
|
||||
L90
|
||||
S5
|
||||
F15
|
||||
W1
|
||||
N5
|
||||
W3
|
||||
F97
|
||||
S3
|
||||
L90
|
||||
S2
|
||||
F78
|
||||
N3
|
||||
W5
|
||||
L90
|
||||
F68
|
||||
E3
|
||||
F24
|
||||
S3
|
||||
L90
|
||||
W2
|
||||
L90
|
||||
F49
|
||||
W4
|
||||
R90
|
||||
F82
|
||||
R270
|
||||
S1
|
||||
N3
|
||||
L90
|
||||
S4
|
||||
R90
|
||||
S2
|
||||
F46
|
||||
L180
|
||||
E4
|
||||
L180
|
||||
W2
|
||||
R90
|
||||
L90
|
||||
N1
|
||||
F88
|
||||
L180
|
||||
S5
|
||||
R90
|
||||
S4
|
||||
L90
|
||||
F68
|
||||
W5
|
||||
F13
|
||||
E4
|
||||
S3
|
||||
F91
|
||||
W3
|
||||
F85
|
||||
L180
|
||||
N4
|
||||
W5
|
||||
S3
|
||||
F89
|
||||
W1
|
||||
L180
|
||||
S2
|
||||
E3
|
||||
F82
|
||||
L90
|
||||
S4
|
||||
W5
|
||||
N5
|
||||
W2
|
||||
S4
|
||||
S2
|
||||
F82
|
||||
E2
|
||||
N4
|
||||
L90
|
||||
F80
|
||||
E2
|
||||
F49
|
||||
W5
|
||||
S3
|
||||
F76
|
||||
L90
|
||||
S1
|
||||
F41
|
||||
S3
|
||||
E1
|
||||
F26
|
||||
E3
|
||||
F53
|
||||
E2
|
||||
F73
|
||||
W3
|
||||
R180
|
||||
N2
|
||||
R90
|
||||
N3
|
||||
R90
|
||||
F16
|
||||
L90
|
||||
N3
|
||||
N1
|
||||
W5
|
||||
F19
|
||||
R90
|
||||
N4
|
||||
W5
|
||||
F6
|
||||
E3
|
||||
N5
|
||||
W2
|
||||
N3
|
||||
E4
|
||||
S4
|
||||
L90
|
||||
E3
|
||||
S2
|
||||
F9
|
||||
L180
|
||||
F70
|
||||
N5
|
||||
S4
|
||||
F63
|
||||
N3
|
||||
E1
|
||||
R180
|
||||
S3
|
||||
L90
|
||||
E5
|
||||
L90
|
||||
F76
|
||||
R180
|
||||
E2
|
||||
L180
|
||||
L90
|
||||
F24
|
||||
E5
|
||||
S5
|
||||
F98
|
||||
S3
|
||||
F97
|
||||
N5
|
||||
R90
|
||||
N5
|
||||
F43
|
||||
W1
|
||||
R180
|
||||
F38
|
||||
R180
|
||||
F13
|
||||
W2
|
||||
F16
|
||||
R90
|
||||
F6
|
||||
N1
|
||||
F98
|
||||
R180
|
||||
N2
|
||||
E1
|
||||
F19
|
||||
L90
|
||||
S1
|
||||
F33
|
||||
R90
|
||||
N3
|
||||
F75
|
||||
N4
|
||||
L180
|
||||
F35
|
||||
W1
|
||||
F61
|
|
@ -1,2 +0,0 @@
|
|||
54755174472007
|
||||
???
|
File diff suppressed because it is too large
Load diff
|
@ -1,2 +0,0 @@
|
|||
32598
|
||||
???
|
|
@ -1,53 +0,0 @@
|
|||
Player 1:
|
||||
44
|
||||
24
|
||||
36
|
||||
6
|
||||
27
|
||||
46
|
||||
33
|
||||
45
|
||||
47
|
||||
41
|
||||
15
|
||||
23
|
||||
40
|
||||
38
|
||||
43
|
||||
42
|
||||
25
|
||||
5
|
||||
30
|
||||
35
|
||||
34
|
||||
13
|
||||
29
|
||||
1
|
||||
50
|
||||
|
||||
Player 2:
|
||||
32
|
||||
28
|
||||
4
|
||||
12
|
||||
9
|
||||
21
|
||||
48
|
||||
18
|
||||
31
|
||||
39
|
||||
20
|
||||
16
|
||||
3
|
||||
37
|
||||
49
|
||||
7
|
||||
17
|
||||
22
|
||||
8
|
||||
26
|
||||
2
|
||||
14
|
||||
11
|
||||
19
|
||||
10
|
|
@ -1,2 +0,0 @@
|
|||
32658947
|
||||
???
|
|
@ -1 +0,0 @@
|
|||
598162734
|
|
@ -1,2 +0,0 @@
|
|||
18433997
|
||||
???
|
|
@ -1,2 +0,0 @@
|
|||
18499292
|
||||
8790390
|
2
2020/day2/vhdl/.gitignore
vendored
2
2020/day2/vhdl/.gitignore
vendored
|
@ -1,5 +1,5 @@
|
|||
workdir/
|
||||
*.o
|
||||
*.ghw
|
||||
day2
|
||||
sim
|
||||
top_syn.vhd
|
||||
|
|
|
@ -1,16 +0,0 @@
|
|||
configuration day2 of sim is
|
||||
for aoc_stdio
|
||||
for dut_inst: dut
|
||||
use entity work.top port map (
|
||||
clk => clk,
|
||||
reset => reset,
|
||||
|
||||
char => char,
|
||||
input_valid => input_valid,
|
||||
|
||||
num_verified => output,
|
||||
output_valid => output_valid
|
||||
);
|
||||
end for;
|
||||
end for;
|
||||
end configuration;
|
|
@ -1,18 +1,14 @@
|
|||
library ieee;
|
||||
use ieee.std_logic_1164.all;
|
||||
|
||||
use work.util.all;
|
||||
|
||||
entity parser is
|
||||
port (
|
||||
clk : in std_logic;
|
||||
reset : in std_logic;
|
||||
|
||||
is_record : in std_logic;
|
||||
is_data : out std_logic;
|
||||
record_end : out std_logic;
|
||||
|
||||
char : in character;
|
||||
input_valid : in std_logic;
|
||||
|
||||
num1, num2 : out natural range 0 to 99;
|
||||
letter : out character
|
||||
|
@ -23,13 +19,23 @@ architecture behaviour of parser is
|
|||
type state_t is (S_NUM1, S_NUM2, S_LETTER, S_COLON, S_END_SPACE, S_DATA);
|
||||
signal state : state_t := S_NUM1;
|
||||
|
||||
type multiples_lookup_t is array(digit_t) of natural range 0 to 90;
|
||||
subtype digit is natural range 0 to 9;
|
||||
type multiples_lookup_t is array(digit) of natural range 0 to 90;
|
||||
constant TEN_MULTIPLES : multiples_lookup_t := (0, 10, 20, 30, 40, 50, 60, 70, 80, 90);
|
||||
|
||||
-- most significant digit of number
|
||||
signal prev_digit : digit_t := 0;
|
||||
signal current_digit : digit_t;
|
||||
signal prev_digit : digit := 0;
|
||||
signal current_digit : digit;
|
||||
signal complete_num : natural range 0 to 99;
|
||||
|
||||
function char_to_digit(input : in character) return digit is
|
||||
begin
|
||||
if input >= '0' and input <= '9' then
|
||||
return character'pos(input) - character'pos('0');
|
||||
else
|
||||
return 0;
|
||||
end if;
|
||||
end function;
|
||||
begin
|
||||
current_digit <= char_to_digit(char);
|
||||
complete_num <= TEN_MULTIPLES(prev_digit) + current_digit;
|
||||
|
@ -37,21 +43,21 @@ begin
|
|||
process(clk)
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
record_end <= '0';
|
||||
|
||||
if reset then
|
||||
prev_digit <= 0;
|
||||
state <= S_NUM1;
|
||||
elsif input_valid then
|
||||
else
|
||||
prev_digit <= 0;
|
||||
|
||||
case state is
|
||||
when S_NUM1 =>
|
||||
if char = '-' then
|
||||
state <= S_NUM2;
|
||||
else
|
||||
num1 <= complete_num;
|
||||
prev_digit <= current_digit;
|
||||
if is_record then
|
||||
if char = '-' then
|
||||
state <= S_NUM2;
|
||||
else
|
||||
num1 <= complete_num;
|
||||
prev_digit <= current_digit;
|
||||
end if;
|
||||
end if;
|
||||
when S_NUM2 =>
|
||||
if char = ' ' then
|
||||
|
@ -68,9 +74,8 @@ begin
|
|||
when S_END_SPACE =>
|
||||
state <= S_DATA;
|
||||
when S_DATA =>
|
||||
if char = LF then
|
||||
if not is_record then
|
||||
state <= S_NUM1;
|
||||
record_end <= '1';
|
||||
end if;
|
||||
end case;
|
||||
end if;
|
|
@ -1,8 +1,25 @@
|
|||
#!/bin/bash
|
||||
#!/usr/bin/bash
|
||||
|
||||
source "$COMMON_DIR/vhdl_run.sh"
|
||||
set -eu
|
||||
|
||||
INPUT=$(readlink --canonicalize-existing "$1")
|
||||
MODE=${2:-}
|
||||
GHDLFLAGS="--std=08 --workdir=workdir"
|
||||
|
||||
cd "$(dirname "${BASH_SOURCE[0]}")"
|
||||
|
||||
DUT_OUTPUT_WIDTH=12
|
||||
test_synth day2 parser.vhdl verifier.vhdl top.vhdl
|
||||
mkdir -p workdir
|
||||
|
||||
if [[ $MODE = "--synth" ]]; then
|
||||
for step in 1 2; do
|
||||
ghdl remove $GHDLFLAGS
|
||||
ghdl synth $GHDLFLAGS -gCOUNTER_WIDTH=12 -gSTEP="$step" parser.vhd verifier.vhd top.vhd -e top > top_syn.vhd 2>/dev/null
|
||||
ghdl analyze $GHDLFLAGS top_syn.vhd sim.vhd
|
||||
ghdl elab-run $GHDLFLAGS sim -gSTEP="$step" --ieee-asserts=disable < "$INPUT"
|
||||
done
|
||||
else
|
||||
ghdl remove $GHDLFLAGS
|
||||
ghdl analyze $GHDLFLAGS parser.vhd verifier.vhd top.vhd sim.vhd
|
||||
ghdl elab-run $GHDLFLAGS sim -gSTEP=1 < "$INPUT"
|
||||
ghdl elab-run $GHDLFLAGS sim -gSTEP=2 < "$INPUT"
|
||||
fi
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
[*]
|
||||
[*] GTKWave Analyzer v3.3.109 (w)1999-2020 BSI
|
||||
[*] Wed Dec 1 11:30:36 2021
|
||||
[*] GTKWave Analyzer v3.3.104 (w)1999-2020 BSI
|
||||
[*] Wed Dec 2 10:02:23 2020
|
||||
[*]
|
||||
[dumpfile] "/home/xiretza/dev/advent-of-code/2020/day2/vhdl/workdir/sim1.ghw"
|
||||
[dumpfile_mtime] "Wed Dec 1 11:29:37 2021"
|
||||
[dumpfile_size] 408417
|
||||
[savefile] "/home/xiretza/dev/advent-of-code/2020/day2/vhdl/sim.gtkw"
|
||||
[timestart] 411833500000
|
||||
[size] 1920 1035
|
||||
[dumpfile] "/home/xiretza/dev/aoc2020/day2/sim.ghw"
|
||||
[dumpfile_mtime] "Wed Dec 2 10:01:08 2020"
|
||||
[dumpfile_size] 410436
|
||||
[savefile] "/home/xiretza/dev/aoc2020/day2/sim.gtkw"
|
||||
[timestart] 410945000000
|
||||
[size] 1600 853
|
||||
[pos] -1 -1
|
||||
*-25.864407 520000000 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
|
||||
*-27.864407 226600000 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
|
||||
[treeopen] top.
|
||||
[treeopen] top.sim.
|
||||
[treeopen] top.sim.top.
|
||||
|
@ -20,10 +20,9 @@
|
|||
@28
|
||||
top.sim.clk
|
||||
top.sim.reset
|
||||
top.sim.top.parser_inst.is_record
|
||||
@420
|
||||
top.sim.top.char
|
||||
@28
|
||||
top.sim.input_valid
|
||||
@200
|
||||
-
|
||||
@28
|
||||
|
@ -34,13 +33,15 @@ top.sim.top.num2
|
|||
top.sim.top.letter
|
||||
@200
|
||||
-
|
||||
@29
|
||||
top.sim.top.record_end
|
||||
@420
|
||||
top.sim.top.verifier_inst.count
|
||||
@28
|
||||
top.sim.top.verified
|
||||
top.sim.top.verifier_inst.verified
|
||||
@200
|
||||
-
|
||||
@24
|
||||
#{top.sim.num_verified[11:0]} top.sim.num_verified[11] top.sim.num_verified[10] top.sim.num_verified[9] top.sim.num_verified[8] top.sim.num_verified[7] top.sim.num_verified[6] top.sim.num_verified[5] top.sim.num_verified[4] top.sim.num_verified[3] top.sim.num_verified[2] top.sim.num_verified[1] top.sim.num_verified[0]
|
||||
@29
|
||||
top.sim.top.record_ended
|
||||
[pattern_trace] 1
|
||||
[pattern_trace] 0
|
||||
|
|
86
2020/day2/vhdl/sim.vhd
Normal file
86
2020/day2/vhdl/sim.vhd
Normal file
|
@ -0,0 +1,86 @@
|
|||
library ieee;
|
||||
use ieee.std_logic_1164.all,
|
||||
ieee.numeric_std.all;
|
||||
|
||||
use std.textio.all;
|
||||
|
||||
entity sim is
|
||||
generic (
|
||||
COUNTER_WIDTH : positive := 12;
|
||||
STEP : natural range 1 to 2
|
||||
);
|
||||
end entity;
|
||||
|
||||
architecture a of sim is
|
||||
signal char_in : character;
|
||||
signal clk, reset, is_record : std_logic;
|
||||
signal num_verified : unsigned(COUNTER_WIDTH-1 downto 0);
|
||||
|
||||
procedure print(s: string) is
|
||||
variable l : line;
|
||||
begin
|
||||
write(l, s);
|
||||
writeline(output, l);
|
||||
end procedure;
|
||||
begin
|
||||
process
|
||||
variable current_line : line;
|
||||
variable current_char : character;
|
||||
variable good : boolean;
|
||||
|
||||
procedure cycle_clock is
|
||||
begin
|
||||
wait for 10 ns;
|
||||
clk <= '0';
|
||||
wait for 10 ns;
|
||||
clk <= '1';
|
||||
wait for 0 ns;
|
||||
end procedure;
|
||||
begin
|
||||
clk <= '0';
|
||||
is_record <= '0';
|
||||
char_in <= NUL;
|
||||
|
||||
reset <= '1';
|
||||
cycle_clock;
|
||||
reset <= '0';
|
||||
cycle_clock;
|
||||
|
||||
lines_loop: loop
|
||||
exit lines_loop when endfile(input);
|
||||
readline(input, current_line);
|
||||
|
||||
is_record <= '1';
|
||||
|
||||
chars_loop: loop
|
||||
read(current_line, current_char, good);
|
||||
exit chars_loop when not good;
|
||||
|
||||
char_in <= current_char;
|
||||
cycle_clock;
|
||||
end loop;
|
||||
|
||||
is_record <= '0';
|
||||
cycle_clock;
|
||||
end loop;
|
||||
|
||||
cycle_clock;
|
||||
|
||||
print(to_string(to_integer(num_verified)));
|
||||
|
||||
wait;
|
||||
end process;
|
||||
|
||||
top: entity work.top
|
||||
generic map (
|
||||
COUNTER_WIDTH => COUNTER_WIDTH,
|
||||
STEP => STEP
|
||||
)
|
||||
port map (
|
||||
clk => clk,
|
||||
reset => reset,
|
||||
char => char_in,
|
||||
is_record => is_record,
|
||||
num_verified => num_verified
|
||||
);
|
||||
end architecture;
|
|
@ -4,18 +4,15 @@ use ieee.std_logic_1164.all,
|
|||
|
||||
entity top is
|
||||
generic (
|
||||
OUTPUT_WIDTH : positive;
|
||||
COUNTER_WIDTH : positive;
|
||||
STEP : natural range 1 to 2
|
||||
);
|
||||
port (
|
||||
clk : in std_logic;
|
||||
reset : in std_logic;
|
||||
char : in character;
|
||||
|
||||
input_valid : in std_logic;
|
||||
|
||||
num_verified : out unsigned(OUTPUT_WIDTH-1 downto 0) := (others => '0');
|
||||
output_valid : out std_logic
|
||||
is_record : in std_logic;
|
||||
num_verified : out unsigned(COUNTER_WIDTH-1 downto 0)
|
||||
);
|
||||
end entity;
|
||||
|
||||
|
@ -24,20 +21,20 @@ architecture behaviour of top is
|
|||
signal num1, num2 : natural range 0 to 99;
|
||||
signal letter : character;
|
||||
|
||||
signal record_end : std_logic;
|
||||
signal prev_is_record : std_logic;
|
||||
signal record_ended : std_logic;
|
||||
|
||||
signal verified : std_logic;
|
||||
begin
|
||||
record_ended <= prev_is_record and not is_record;
|
||||
|
||||
parser_inst: entity work.parser
|
||||
port map (
|
||||
clk => clk,
|
||||
reset => reset,
|
||||
|
||||
record_end => record_end,
|
||||
is_record => is_record,
|
||||
is_data => is_data,
|
||||
|
||||
char => char,
|
||||
input_valid => input_valid,
|
||||
|
||||
num1 => num1,
|
||||
num2 => num2,
|
||||
|
@ -48,8 +45,8 @@ begin
|
|||
verifier_inst: entity work.verifier(step1)
|
||||
port map (
|
||||
clk => clk,
|
||||
reset => reset or record_end,
|
||||
enable => is_data and input_valid,
|
||||
reset => reset or record_ended,
|
||||
is_data => is_data,
|
||||
num1 => num1,
|
||||
num2 => num2,
|
||||
letter => letter,
|
||||
|
@ -60,8 +57,8 @@ begin
|
|||
verifier_inst: entity work.verifier(step2)
|
||||
port map (
|
||||
clk => clk,
|
||||
reset => reset or record_end,
|
||||
enable => is_data and input_valid,
|
||||
reset => reset or record_ended,
|
||||
is_data => is_data,
|
||||
num1 => num1,
|
||||
num2 => num2,
|
||||
letter => letter,
|
||||
|
@ -75,13 +72,13 @@ begin
|
|||
process(clk)
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
prev_is_record <= is_record;
|
||||
if reset then
|
||||
prev_is_record <= '0';
|
||||
num_verified <= (others => '0');
|
||||
elsif record_end and verified then
|
||||
elsif record_ended and verified then
|
||||
num_verified <= num_verified + 1;
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
|
||||
output_valid <= '1';
|
||||
end architecture;
|
|
@ -5,7 +5,7 @@ entity verifier is
|
|||
port (
|
||||
clk : in std_logic;
|
||||
reset : in std_logic;
|
||||
enable : in std_logic;
|
||||
is_data : in std_logic;
|
||||
|
||||
num1, num2 : in natural range 0 to 99;
|
||||
letter : in character;
|
||||
|
@ -24,7 +24,7 @@ begin
|
|||
if rising_edge(clk) then
|
||||
if reset then
|
||||
count <= 0;
|
||||
elsif enable then
|
||||
elsif is_data then
|
||||
if char = letter then
|
||||
count <= count + 1;
|
||||
end if;
|
||||
|
@ -45,7 +45,7 @@ begin
|
|||
if reset then
|
||||
count <= 1;
|
||||
parity <= '0';
|
||||
elsif enable then
|
||||
elsif is_data then
|
||||
count <= count + 1;
|
||||
if (count = num1 or count = num2) and char = letter then
|
||||
parity <= not parity;
|
|
@ -1,2 +0,0 @@
|
|||
278475
|
||||
3015539998
|
|
@ -1,110 +0,0 @@
|
|||
{<<<[<(<{[[[[<<><>>({}())]<<[]{}>{<><>}>]]<({<[]{}>}<[[]{}]{[]<>}>){({{}<>}[<>[]))<({}())<{}<>>>}>]([{[<{}<>
|
||||
{{{<(<<{<([[<{[][]}<<><>>>{{(){}}}]<{[{}{}][<><>]}[[[]()][()[]]]>])(<{([[]][<>{}])[([]<>){[][]}]}(([[]()]
|
||||
(([{<{<<{((({[()[]]([][])}[{()}(<>)])[<(()<>)>(([])[{}[]])]){{([()()){[]()})}})}({<<[(()<>){()}
|
||||
{[[{[[[{[[<(({{}}{{}()}){{()<>}{<>()}})>({<{(){}}>{(<>{})(())}}((({}()))({[]()}<()()>)))]<(
|
||||
<<[({({(((<<[[<>{}]{<>()}]{[<>{}][[]()]}>([[<>]]{{<><>}[<>[]]})>)){[<[[<<>()>{<>{}}][(()<>){[]{}}]]>}<[[<
|
||||
({<([{({{<{{<{(){}}<()[]>><{()<>}(()())>}[([{}[]]<<>{}>){<[][]>({})}]}<{({{}[]}<[][]>)((<>{})(()<>))}<{<{}(
|
||||
{([{{[({[<<(([[]()])<(<>())[<>[]]>]{([[]{}]([]()))}>([{{[][]}({}{})}(([]{})[[]<>])])>[<<[{<><>}[
|
||||
<[<([<(<<{{<(<[]<>>)><(<{}[]>[[][]]){{{}()}[[]()])>}}><[<(({<><>}{(){}})([<>[]]))>]>>{[<<[{([]{})[<>{}]}[
|
||||
{{{{({((((<{[([]{})<<>{}>]({<>})}<(<()<>><[]{}>)<(()())({}<>)>>>)<{[{{<>{}}}]}([[{()()}{[]()}
|
||||
[<(({((<{{<({(()())((){})}[[()<>]{{}[]}])<<[()<>]><{<>{}}{<>{}}>>>}{(((<<>{}>{()[]})([[][]][(){}]))[(<
|
||||
<<[({{<{{<({<{<><>}(<>[])>{[[]{}][()]}}){<<([]())(()<>)>[{()[]}]><[[<>{}]({}())](<[]<>>{<>()})>}>{[
|
||||
{{(({<[[<<{{{<[]{}>({}())}}{{[{}()]<()()>}((<>{}})}}<{<[()()]{[][]}>(((){}){{}[]})}>>[{<[[<>[]](())]
|
||||
[((({{{({[<(<({}<>)<{}[]>>)[[[[][]](()[])]({{}{}}{()[]})]>[(<[<>()][<>()]>[[[]()]((){})])]
|
||||
{<<<{[<{<{<[{[<>]<[]()>}{<<>[]><()<>>}]>{[[<(){}>({}())][{()[]}{{}<>}]](<[[]<>]{()<>}>[{[]{}}[
|
||||
{<[<[{({[<{{{{<><>}{{}()}}{<<><>>(<>{})}}{[{{}{}}<()<>>]{[<>{}]}}}({[[{}()]<{}[]>][<{}<>><[]{}>]}{<<<>
|
||||
(<[<([<[{(<(({[][]}(()[]})[<{}()><{}()>]){[[{}[]]{{}<>}]}>{[{<{}()>{{}()}}<<<>{}>{[]<>}>]})(<{{(<><>
|
||||
[[{{[[({[[[<{(<><>)<{}()>}({<>{}}(()<>))>]<<[{()()}[<>]]<{[]()}[<><>]>>>][<{(({}<>)){<{}{}}[[]{}]}
|
||||
(((<[({[([({[([]{})[<>()]]<{(){}}(()())>}[{(()<>]<{}{}>}[{{}<>}<{}()>]]){<<[<>()]<[]>><[[]()](<>(
|
||||
[(({{<[([{<<[{[]{}}<[]{}>]({()[]}[()])>>}])<{{{[({<>[]}(<>[]))([{}()]({}[]))]<{[{}()]{{}<>}}{<{
|
||||
<[(<[<[{<<{(<[<>{}]<[]()>>{((){}){()<>}})}<<<[{}{}][<><>]>>(([()()][<>]){<{}()><<><>>})>>[{({<{}
|
||||
{(<{<{[<{<({<{[]<>}[<>()]]<[[][]][()()]>}({({}<>){<><>}}[<<>()>{[][]}])){[[{<>()}({}[])](({}[])<{}>)]([
|
||||
{([<{<(([<{[[<<>><[]()>]{(<>{})[{}{}]}}[((()()){<>[]})[(<>[]){()<>}]]}>])([{([<(<>())[{}<>]>][[(()<>)<{}[]>
|
||||
[(((<[<{{<[<{{{}[]}}><<<()[]>({}<>)>{{{}[]}[<>()]}}]{{{({})[{}()]}({(){}}<{}[]>)}({({}[])(())}{(<><>)[<>{}]}
|
||||
{{[(<{(<[<[<<{{}}[()()]>><[({}{})][<{}()><{}>]>]{[{[{}][<><>]}[[()()]([]{})]]{{({}()){(){}}}<{[]{}}<
|
||||
[{{<{<([(<[<[{()[]}]{<(){}>}>[([()<>][<>()])[{()<>}[<>[]]]]]>)])>}{([[<{<{{[()<>]{()()}}<[<><>]<<>[]>>)[{[()(
|
||||
<(({<[[[[(({({<>[]}[{}])<<{}()>{(){}}>}{({{}[]}{()[]}){{<><>}[<>{}]}})<[{{()()}[()()]}]({{<><>}<()()>}[<(
|
||||
({{{([{<{[[[[<[]()>{(){}}]{([]{})[{}[]]}][[{[]()}]<[()[]](<>[])>]]((<[<><>]{(){}}><<{}{}>>))]}(
|
||||
([<[({[[([{<(<<>()><{}[]>){[()[]][(){}]}>}({((<>()){()()})}{({{}()}<<>()>){[{}]<[]()>}})])([<(
|
||||
{<<[[<(([({[<[[]]((){})><{[]()}{()<>}>]}<<(<<><>>(()())){{<>{}}}>>)]])<(<<<<[{{}()}[[]()]]((()))>(
|
||||
[[{{{[[[[(<{[(()[])[[]]][(()[])((){})]}[{{<><>}{{}()}}([[]()])]><([<<>()>{{}()}])>)({([[[]]>{<()<>>[{}<>]}
|
||||
{{({[{<<<[(({[<>[]>{<>()}}){<{[]<>}>({{}<>}<()>)})(<{(()())<()()>}({[][]}[(){}])>(<[()[]][<>[]]>[{()<>}
|
||||
({[[[<[<[{[({<<>()><<><>>}{{<>()}<()<>>})]<<[[<><>]<[]()>][[()][{}{}]]>{[{[]{}}([]<>)]<({}{})(<>{})>}>}]>[[{[
|
||||
<<<(({{{[{([(({}{})([]<>))<[<><>]{<>{}}>]<(<<>[]>(<>[]))[([]<>)[()[]]]>)(<[[()()]{[]{}}][{()[]}{(){}}]>[<({
|
||||
{[[((([[<{{{(<(){}>{<>()})}}}[((<([]<>)[[][]]>{<{}[]>[<>]})[{[(){}]}{<(){}><<>()>}])<{([[]<>])[((){}
|
||||
{[[(({{{<<<<[<[]<>>]><[{<>{}}]([{}<>]<()()>)>>>{[[<<[]{}>>[{<>()}]]{[{[][]}{[]()}][{(){}}[()]]
|
||||
<[([([[[[(([((<><>)[<>]){([][]){[][]}}]({[()[]>{()[]}}{{<>{}}(()[])}))){<<{<{}[]>{{}()}}><[[<>[]]<<><>>]
|
||||
{(([{([(<[((<<[][]>((){})>)<((<>{}){[][]})(<<>[]>)})]><[((((()){<>()})[{[]()}{<>{}}]))]>)[[<<<{[<
|
||||
{([([(({[{{<([<>[]][<>{}])>([<{}()>(<>)]{[()[]]<[]<>>})}<[[[[]()][{}{}]]([()()])][(<()()>[()[]
|
||||
{<(<({({<(<[{<{}()>[<><>]}[{()[]}{{}<>}]]{[{[]()}<<>{}>]([[]<>](<>()))}>(([[[][]](<>())})[({<><>}[()<>])]))>}
|
||||
<((<(<<<{{{<[<[][]>([]{})]><(<(){}>[()<>])>}<[{<[][]>{<><>}}](({{}<>}))>}[<{{(<><>)<<><>>}(<[]{}>[[]()])}>
|
||||
[<<{{(<[{<([[[(){}]<{}{}>]<[{}()]>][[{{}()}[()<>]](<<><>>[{}<>])])([<({}{})[{}<>]>{{()()}}]{[{[
|
||||
[[[<[<<{{{[[[[[]{}](()())]]{{{<><>}((){})}[({}<>)([][])]}]({[[<><>]([][])][{<>{}}(()())]}{[[<>[]]
|
||||
{(<[[[<{<<[[{{{}[]}[{}{}]}<<<>()>[{}{}]>]({{[]{}}{[]<>}}<<(){}>[()]})]<[{({}[])[()()]}<[<><
|
||||
[<[<([{({[{<(<<><>>[()<>])[[{}<>][<>[]]]><[<()<>>]<([][])>>}<({{<>{}}{{}{}}}([()()][(){}]))[<({}<>)([]())>({[
|
||||
[{[[<[{{{{[{(({}[])(()()))([(){}]{[]{}})}][{<(<>())<{}()>><({}[])[()<>]]}<<[[]{}][[]()]>{{
|
||||
{<{<[<<{[{<[[[(){}]][({}{}){()<>}]]({[<><>](<>{})})>[{{[{}[]]<<>{}>}[[(){}]([][])]}{(({}[]){[]
|
||||
[<((<<{((([<{<()()>[{}[]]}[<[][]}<()()>]>]<[<[<><>]{()<>}><{(){}}<(){}>>]>){{[([{}<>][(){}]){{[
|
||||
<[{(<<<<<{[<[<()<>><(){}>]>{[{()()}[()[]]]}}}{[<{[{}{}]([][])}(([]{})[(){}])>]{<[{(){}}[()<>]][({}[]){()()}]>
|
||||
{<{{[({{<{[<{(<>()]{<>{}}}<<<><>>{()<>}>>[{([]{})}<{[]()}{<>[]}>]][([<()[]>{<>{}}]([{}{}]{(){}})
|
||||
<({([({[(<[(({[]()}{{}()}){[(){}]})][{<<<>[]>{()()}>}(<{{}<>}{[][]}>{[<><>](<>())})]>[[[{({}{})<(){}>}
|
||||
[(<[[[<[{(([{{<>{}}([]{})}[{<>()}{<><>}]]<{(()())<{}[]>}{(<>)[<>[]]}>){{({<><>}(()))}({<[]{}>{<>[]}})})
|
||||
<[{([([[([<[([()()]((){})){([]())(()[])}]<<{()[]}<{}[]>>{{[]()}<<>[]>}>>(<[<[]{}>[{}]]>)][(
|
||||
(([<<(<[<<[<[[()()]{[]()}}{<{}{}>{{}<>}}>[<<<>()>[[]{}]>[({})[<>()]]]](<{{<>[]}[{}{}]}[(()())]>[[{{
|
||||
[{<[<((((([{(<[]()>([]{}))<[<><>]>}[(([]{})[{}{}])<({}())<[]<>>>]])))))([<<({<<[{}{}]><{()<>}{[]()
|
||||
<<[<<[[[<{<[{{<>()}(<>{})}([[][]])]{[(<><>)(<><>)]((()<>)[()[]])}>[<[<()[]>[(){}]]((<>())[()<>])>]}>]]
|
||||
<<{<[([[((<[[{<>{}}]<[()<>]([]{})>]{<({}<>){()()}><<()()>>}>[<<<<>()>{[]()}><<()()><<>()}>>])
|
||||
{(<[{{([{<(<{[{}{}]<<><>>}([<>{}][[]()])>(([<>[]])[{{}[]}{{}{}}]))[(({<>()}<()()>){([]{}){[]
|
||||
{<[<<[<[<<{[(<{}{}>)<[<>[]](<><>)>]{(({}<>)[<>[]]){<{}<>>([]{})}}}>[[<[[{}()]{[]()}]>]{[{{{}()
|
||||
(<<<<<<<([{(<[<>{}]([][])>{{[]<>}])}{<<<()<>><()()>>[{{}()}[{}{}]]>[[[{}()][[]<>]]{<{}[]>[(){}]}]}])
|
||||
([<[<[[{[(<<{([][]){<>()}}[<()<>>(()[])]>{{(())(()())}{({}[]){[]()}}}><[([(){}])({{}{}})]>)(({[[[][]
|
||||
<(<[[<([{<([<[[][]]({}())>>){{(([])[<><>])<{<>[]}[{}()]>}{[<()>[{}{}]]((()[]){<>})}}>}[<<{[[()
|
||||
({<<{[{[(({{<{()()}>[(<>[])]}[([{}<>]{[]{}}){{{}()}<{}<>>}]}{<({[]}[{}()]){{(){}}[<>{}]}><{[<><>
|
||||
({<[([[(<{<{{[[]<>](()[])}{<[]<>>(<>[])]}>{[[{{}{}}][{<>[]}(<>)]]<<<()()>({}<>)><<{}()>{{}()}>>}}>[(<[(<{}<>>
|
||||
[[((<{<<[{{<<<[][]><[]{}>>>{[<()()>]<<[]<>>((){})>}}}{<(<((){}){{}<>}>[([]<>)<{}[]>])<[[{}{}](<><>)]{([
|
||||
<{{({([([{{((({}<>)(()()))[(<>{})<[][]>])(<{<><>}([]<>)>{(()[])[[]{}]})}{<{{{}()}({}())}[([]{
|
||||
{<[(<{[<{[[(<<{}<>>[[]<>]>}{[<[]<>>[{}()]]{[{}](<>)}}]]}{{({(<{}{}>[()[]])[[{}{}][{}]]}<<<<>{}>>[([][
|
||||
({<{<<[([<[[<<{}[]>(()[])>][[([][]>[<><>]]{{()}}]](<((<>[])<<><>>)[({}()){{}[]}]><([[]<>]{<>[]})
|
||||
<{({[{{{<[<[{<()()><{}[]]}{[[]{}]([]<>)}]{{([]()){<>()}}{{{}<>}({}<>)}}>[<<<[]()>[{}[]]><(()())[<>[]]>>(
|
||||
{(([((<[<({{{<()()>[()<>]}<[{}{}]<<>[]>>}(<{[]()}{()[]}>([{}[]]({}())))}({{<{}{}>[<>{}]){{[]()}{[]<>}
|
||||
(([({{[[(<[<(<<><>>[[]()]){([]())({}<>)}>[((()()){()()})[({}())<[]()>]]]>[{{<[{}{}][{}()]>}{([<><>]<
|
||||
[[{<{([<[{(((<()()>{{}[]}}<<{}{}>[{}[]]>){(((){})[{}<>])<<(){}>(<>{})>})}(([<(<><>)<[]<>>>([<>()])]<[({}{
|
||||
<[{(<[(<<{<{<({}{})<(){}>>([[]{}]{()<>})}[{{[][]}[[]]}([()](<>()))]>[{(({}[])(()())>([{}])}{(<[]()>{
|
||||
<{({{<{{{{{{<[()()]([]{})>{([]{})[()()]}}}}}}({(<[{([]{})({}{})}{(<>())<{}<>>}]({{<><>}}[{()<>}[[
|
||||
{{[({(<{[([[<<()()>{()[]}><{()<>}{{}{}}>]]<{[{()<>}(()<>)][<{}{}>([][])]}<{<[][]>[()()]}<{()<>}[[][]]>>>)]
|
||||
(<({{({{{([({{{}()}{(){}}}<{(){}}<<>[]>>)(<[[]<>][<>{}]><[<>{}]>)]{[{(()[])}{[[]<>]{{}}}]((((){}){<>
|
||||
<(([(((((((({([]<>)}<(()<>)<<>[]>>)[{[[]{}][()<>]}<{()<>}>])<<<{(){}}[<>()]>{(()()){[]<>}}>
|
||||
<<<<{{{[[([<{{<>()}[{}<>]}<<(){}><[]{}>>>([[[]()]<{}()>})]({[[{}()]{<>()}][{[]<>}[(){}]]}))((
|
||||
{[(<<<<({(<[[{{}}]<(()<>)<{}<>>>]<([[][]]({}<>)){[()[]]<(){}>}}>)}[[[([[[]<>]<()()>][{[]{}}])[[
|
||||
(<((<((<<([((<<>()>(<>()))<{<>()}([][])>)[[({})<{}<>>]]])>(<{(({()[]}(<><>)){{()[]}{()()}])}<({<()<>>({}
|
||||
[(<<<(<<{{({<[<>[]]([]()]><<<>()><<><>>>}[<[<>{}]((){})>(([]{}){(){}})])<<[{<>()}<{}()>]({
|
||||
([[{<[[<[{(<<(<><>)>({<><>}{<>[]})>[{[[]{}]({}{}))])}{(<((<><>)(()[]))><([<><>]{()[]})[{<>
|
||||
<<[[<{<<<[{[<(<>[])>{{{}<>}(()[])}][({[]{}}(<>()))<(<><>){{}()}>]}{{{(()<>)<<>{}>}<<[][]>>}[([[][]]{()()}))}]
|
||||
(([({{{<<{{{<[(){}]{[]()}>({{}()}({}{}))}}{([{()<>}<()>](([][])<<>[]>)){{<<><>>{()}}{<{}<>><[]<>>}}}}{[<[[[][
|
||||
[([{<{{[([<((({}{})[<><>])<{{}{}}<()()>>)>{(<[()[]][<>{}]>(<()[]>[()<>]))([(<>[])<{}{}>]{<{}()>[<>[]]})}
|
||||
[<<<[(<((<(<{(<>[]){<>{}}}{{<>{}}}><[(()[])(()())][<[]{}><<>{}>]>)>[({<[()<>]({})>})])(<[[({<><>}{(){
|
||||
{{(<({<<{([{[<<>()}<{}[]>][{<>{}}[{}{}]]}{{[[]<>]{{}()}}}][({([]{})<()()>}){{({}[]){()}}{{()}
|
||||
{({((({[([<(({()<>}[{}<>])[<<><>><()()>])<[(()[])<{}()>]{[[]()]({}<>)}>>[({<()<>)})]]<{<<{{
|
||||
<<({[([{[{<<<[()<>]{()<>}>{([][])[<>[]]}>{({<><>})[{[][]}<{}{}>}}><<({{}()}<{}()>)><[(()[]){()()}][<()<>>{[](
|
||||
[([<({<{[<[<<<(){}><{}[]>>([{}[]])><{<[]<>>[{}()]}[<{}<>>{(){}}]>][(({{}()}[{}<>]))(<{[]()}(())>{
|
||||
<<([(<(({{{[{(<>()>[{}()]}[<[]{}>({}())]]}<{({{}()}[<>{}])}{<(<>[])({}<>)>{<[]()><[]<>>}}>}{{[{[
|
||||
{<([<{{<(<({<({}<>){()<>}>(<(){}>([]{}))})>({{[([]())([]())]}<[[{}{}>[<><>]]{([]())<{}()>}>
|
||||
[[{({[<{<({[{{<>[]}[(){}]}<[<><>]{[][]}>][{{(){}}<<>[]>}[{(){}}[()[]]}]}{{(<<>{}>[{}[]])<{()[]}[<>{}]>}
|
||||
{(({{[[{{[([({<>[]}[[]<>])[{()()}<()[]>]]){(<{[]{}}{[]{}}>(<(){}>{[]<>}))((<{}<>>{(){}})<[<>()
|
||||
<{[<([[<{<[{{{()<>}<[]()>}{[()]([]())}}<<[(){}]([][])>{{[]{}}<[][]>}>]<([{{}()}[<>{}]])<[<[]<>><()
|
||||
({[<<[<{([{[({(){}}{()[]})<<[]()>>]<[{()[]>{()<>}][<{}>{[]()}]>}[([<(){}>(())])({[()()]<<>{}>}<{{}{}}
|
||||
[[<{[{{[{[[{({{}[]})}]](<<<(()<>)><({}{})<{}{}>>>([<{}<>>(()[])][<<>()>])>)}<(<<([()[]][()[]])<{()
|
||||
[{([(({<{<([(({}<>)[{}()])])><{[[{[]<>}<<><>>]<<[]<>><(){}>>]}{{<<(){}>{<>()}>[<{}{}>{<>[]}]}[<[()()]
|
||||
<[[[<({[[<{{<(<>())(<><>)>{[(){}][{}<>]}}({({}<>){{}[]}])}[[(<{}{}>[()[]])]{(([][])<()>)[({}())<{}()>
|
||||
{[[(<(<{<([[(([]{})[<>()])<<[]>[()[]]>](<{()[]}[[]<>]>{[()<>]([]())})][([<{}<>>[{}[]]]{<[]>(<>)
|
||||
<[<[[<<(({[(<[[]]{<>[]}>{(<>())(()())})<({(){}}{[][]})>]([{<()()><[]()>}[{[]()}[[][]>]]{{(())}(({}{})<<>[
|
||||
(({<{{[{(<[[[<<>()>][{<>()}[[]<>]]]]{{{{<><>}({}{})}{{[][]}({}[])}}{[{{}<>}{[]()}]}}>{<([[
|
||||
<([<{([([[{{[{{}{}}<{}()>]<{{}{}}>}({{(){}}{<>()}}[<(){}>[()()]])}[<{{<>[]}[()()]}{{{}[]}{[]<>}}>]]{[{<
|
||||
<{({{[<{<(({[({}<>)[[]<>]]<<[]{}>(()<>)>}))[<{((<>[])[<><>])<((){}][()()]>}{<([]{})(<><>)>}>{(
|
||||
{<<<<([{[<[{<<(){}>({}{})>}<<{[][]}{<>()}>({{}()}([]{})))]((({<><>}<{}[]>)({[]()}{<>()}))[[<{}{}>][{[]()
|
||||
[(<(<[(<{({[<(<>{})[()()]>[([]{}){[]<>}]]{{<{}{}>(<><>)}<{{}()}((){})>}}<<{{()[]}((){}}}{{
|
||||
{<<<[(<([{<<([()()][()])<{[]<>}[<>()]>>[<(()())<<>{}>>({[]{}}([]<>))]>}])>)([([{{{[[[]()](()
|
||||
<<({<{<([([[<[(){}]<<><>>><{()[]}[(){}]>]<(<{}[]>){[[]<>](()[])}>][<[<(){}>[{}[]]]({[][]}((){}))>
|
||||
{([{{[(<({{<(<[][]>{()()}){[{}()]}><(<<>())<[]{}>){<{}{}>((){})}>}}((<(<<>[]><()()>)><{[[][]]}<[<>
|
||||
[(<{{[{[{<([[[{}[]]<<>>]][[(()[])[(){}]]])({([<>[]]({}<>)){([]{})({}[])}}({(())({}[])}<{<>[]}(()[])>))
|
||||
({[([(<{<(<<(([][])(()()))({[]()}(<>[]))><({{}()}[[]()])>>)>[<[([{()<>}<[]<>>]([{}<>]{()()}})<[<{}
|
|
@ -1,2 +0,0 @@
|
|||
4411
|
||||
136767
|
|
@ -1,24 +0,0 @@
|
|||
yb-start
|
||||
de-vd
|
||||
rj-yb
|
||||
rj-VP
|
||||
OC-de
|
||||
MU-de
|
||||
end-DN
|
||||
vd-end
|
||||
WK-vd
|
||||
rj-de
|
||||
DN-vd
|
||||
start-VP
|
||||
DN-yb
|
||||
vd-MU
|
||||
DN-rj
|
||||
de-VP
|
||||
yb-OC
|
||||
start-rj
|
||||
oa-MU
|
||||
yb-de
|
||||
oa-VP
|
||||
jv-MU
|
||||
yb-MU
|
||||
end-OC
|
|
@ -1,7 +0,0 @@
|
|||
704
|
||||
#..#..##...##....##.###..####.#..#..##.
|
||||
#..#.#..#.#..#....#.#..#.#....#..#.#..#
|
||||
####.#....#..#....#.###..###..####.#...
|
||||
#..#.#.##.####....#.#..#.#....#..#.#...
|
||||
#..#.#..#.#..#.#..#.#..#.#....#..#.#..#
|
||||
#..#..###.#..#..##..###..####.#..#..##.
|
|
@ -1,852 +0,0 @@
|
|||
43,593
|
||||
1139,385
|
||||
1178,51
|
||||
216,679
|
||||
743,185
|
||||
1241,250
|
||||
197,60
|
||||
479,700
|
||||
565,845
|
||||
1022,330
|
||||
744,714
|
||||
440,535
|
||||
137,81
|
||||
35,766
|
||||
482,249
|
||||
1120,280
|
||||
484,98
|
||||
301,823
|
||||
928,616
|
||||
601,7
|
||||
60,835
|
||||
1092,371
|
||||
1033,584
|
||||
1079,833
|
||||
44,665
|
||||
469,777
|
||||
915,526
|
||||
759,290
|
||||
843,891
|
||||
1225,464
|
||||
326,831
|
||||
723,333
|
||||
1099,362
|
||||
962,285
|
||||
1069,474
|
||||
315,731
|
||||
716,506
|
||||
741,430
|
||||
1228,320
|
||||
1099,878
|
||||
485,522
|
||||
328,333
|
||||
1289,432
|
||||
1173,506
|
||||
395,526
|
||||
47,625
|
||||
1155,273
|
||||
114,856
|
||||
914,826
|
||||
1263,849
|
||||
1294,693
|
||||
607,289
|
||||
1225,138
|
||||
25,519
|
||||
1051,564
|
||||
738,747
|
||||
67,493
|
||||
1178,619
|
||||
984,828
|
||||
21,100
|
||||
1086,241
|
||||
644,563
|
||||
164,287
|
||||
738,131
|
||||
1116,312
|
||||
21,796
|
||||
423,66
|
||||
395,816
|
||||
846,614
|
||||
823,63
|
||||
249,542
|
||||
858,162
|
||||
1273,448
|
||||
684,623
|
||||
139,443
|
||||
184,388
|
||||
977,71
|
||||
499,621
|
||||
810,133
|
||||
1169,346
|
||||
249,791
|
||||
47,772
|
||||
1170,128
|
||||
530,162
|
||||
594,387
|
||||
972,752
|
||||
1309,752
|
||||
26,707
|
||||
211,362
|
||||
821,640
|
||||
502,722
|
||||
872,63
|
||||
93,82
|
||||
895,709
|
||||
1113,445
|
||||
567,338
|
||||
592,448
|
||||
567,556
|
||||
552,277
|
||||
815,735
|
||||
10,470
|
||||
400,120
|
||||
807,835
|
||||
1289,602
|
||||
470,442
|
||||
167,562
|
||||
1094,735
|
||||
848,467
|
||||
1275,568
|
||||
1009,868
|
||||
264,829
|
||||
907,95
|
||||
894,714
|
||||
807,59
|
||||
768,199
|
||||
470,218
|
||||
141,346
|
||||
644,22
|
||||
85,430
|
||||
693,670
|
||||
489,640
|
||||
748,555
|
||||
535,560
|
||||
1056,597
|
||||
617,266
|
||||
445,149
|
||||
751,269
|
||||
535,782
|
||||
1046,494
|
||||
372,677
|
||||
62,848
|
||||
1111,291
|
||||
1048,313
|
||||
1069,868
|
||||
480,387
|
||||
487,640
|
||||
1151,463
|
||||
725,194
|
||||
1031,528
|
||||
139,675
|
||||
994,304
|
||||
223,604
|
||||
823,679
|
||||
383,793
|
||||
313,189
|
||||
463,357
|
||||
952,275
|
||||
38,477
|
||||
127,155
|
||||
1156,245
|
||||
1277,371
|
||||
572,315
|
||||
279,810
|
||||
908,322
|
||||
436,397
|
||||
594,835
|
||||
1031,93
|
||||
1173,813
|
||||
733,327
|
||||
982,828
|
||||
495,640
|
||||
703,737
|
||||
1017,299
|
||||
390,0
|
||||
99,327
|
||||
1084,458
|
||||
202,732
|
||||
551,604
|
||||
259,816
|
||||
85,464
|
||||
1083,525
|
||||
301,26
|
||||
822,352
|
||||
703,157
|
||||
539,434
|
||||
550,194
|
||||
868,710
|
||||
197,893
|
||||
758,586
|
||||
736,176
|
||||
633,889
|
||||
115,460
|
||||
256,80
|
||||
651,672
|
||||
1064,409
|
||||
872,7
|
||||
669,745
|
||||
231,604
|
||||
88,628
|
||||
759,604
|
||||
1287,694
|
||||
171,826
|
||||
1222,852
|
||||
1250,836
|
||||
1092,54
|
||||
85,196
|
||||
388,205
|
||||
907,543
|
||||
326,561
|
||||
264,381
|
||||
775,560
|
||||
1069,71
|
||||
60,836
|
||||
277,584
|
||||
375,801
|
||||
117,813
|
||||
1181,673
|
||||
1150,128
|
||||
54,278
|
||||
718,446
|
||||
577,327
|
||||
1004,733
|
||||
1084,794
|
||||
909,497
|
||||
975,807
|
||||
561,171
|
||||
244,819
|
||||
505,441
|
||||
393,64
|
||||
502,172
|
||||
517,872
|
||||
268,28
|
||||
1113,210
|
||||
141,490
|
||||
185,826
|
||||
301,250
|
||||
354,654
|
||||
234,471
|
||||
403,95
|
||||
438,887
|
||||
693,166
|
||||
189,709
|
||||
1243,493
|
||||
87,543
|
||||
1086,777
|
||||
338,752
|
||||
49,584
|
||||
574,148
|
||||
1039,607
|
||||
1051,116
|
||||
569,375
|
||||
254,326
|
||||
554,212
|
||||
1255,271
|
||||
1042,866
|
||||
30,119
|
||||
218,632
|
||||
674,372
|
||||
10,582
|
||||
596,194
|
||||
194,582
|
||||
880,450
|
||||
587,828
|
||||
723,666
|
||||
109,290
|
||||
85,711
|
||||
915,116
|
||||
259,564
|
||||
259,609
|
||||
189,721
|
||||
383,607
|
||||
666,22
|
||||
326,828
|
||||
164,152
|
||||
709,362
|
||||
755,145
|
||||
108,483
|
||||
657,640
|
||||
716,507
|
||||
1,752
|
||||
1272,788
|
||||
664,46
|
||||
316,470
|
||||
882,458
|
||||
693,266
|
||||
1089,326
|
||||
1121,519
|
||||
1120,483
|
||||
499,68
|
||||
547,719
|
||||
1066,355
|
||||
1014,757
|
||||
971,163
|
||||
868,856
|
||||
161,702
|
||||
75,2
|
||||
566,516
|
||||
1178,760
|
||||
266,651
|
||||
1099,464
|
||||
863,201
|
||||
224,53
|
||||
1113,1
|
||||
811,273
|
||||
177,453
|
||||
775,245
|
||||
1297,694
|
||||
764,408
|
||||
137,813
|
||||
716,429
|
||||
908,469
|
||||
1225,127
|
||||
1031,794
|
||||
428,458
|
||||
925,305
|
||||
581,721
|
||||
306,733
|
||||
1258,854
|
||||
241,138
|
||||
1181,834
|
||||
987,3
|
||||
796,94
|
||||
218,497
|
||||
100,682
|
||||
1180,122
|
||||
184,218
|
||||
1218,23
|
||||
569,16
|
||||
1250,725
|
||||
1202,49
|
||||
736,829
|
||||
1059,674
|
||||
684,735
|
||||
428,346
|
||||
1195,434
|
||||
1064,485
|
||||
430,450
|
||||
224,761
|
||||
749,364
|
||||
711,549
|
||||
276,7
|
||||
403,367
|
||||
855,291
|
||||
375,541
|
||||
85,586
|
||||
353,644
|
||||
467,667
|
||||
50,617
|
||||
1225,308
|
||||
751,161
|
||||
751,340
|
||||
703,289
|
||||
422,457
|
||||
442,710
|
||||
85,127
|
||||
1307,670
|
||||
1079,526
|
||||
639,820
|
||||
1217,171
|
||||
378,613
|
||||
952,585
|
||||
731,450
|
||||
402,693
|
||||
847,357
|
||||
195,696
|
||||
25,362
|
||||
1274,460
|
||||
160,766
|
||||
231,302
|
||||
1084,548
|
||||
927,773
|
||||
1280,438
|
||||
487,679
|
||||
261,88
|
||||
1054,80
|
||||
129,221
|
||||
1171,107
|
||||
1195,12
|
||||
920,0
|
||||
851,248
|
||||
828,649
|
||||
1307,137
|
||||
710,168
|
||||
50,56
|
||||
555,749
|
||||
345,712
|
||||
266,329
|
||||
830,611
|
||||
296,760
|
||||
633,432
|
||||
232,457
|
||||
184,429
|
||||
611,749
|
||||
37,224
|
||||
402,469
|
||||
666,779
|
||||
1217,364
|
||||
423,340
|
||||
296,7
|
||||
443,878
|
||||
378,10
|
||||
1139,509
|
||||
1228,635
|
||||
629,698
|
||||
539,205
|
||||
910,297
|
||||
500,133
|
||||
684,271
|
||||
703,605
|
||||
21,453
|
||||
1110,476
|
||||
841,68
|
||||
351,648
|
||||
1252,780
|
||||
234,646
|
||||
780,641
|
||||
308,715
|
||||
416,180
|
||||
957,250
|
||||
935,532
|
||||
761,863
|
||||
401,397
|
||||
1252,642
|
||||
827,826
|
||||
874,262
|
||||
244,406
|
||||
572,579
|
||||
338,53
|
||||
58,642
|
||||
1307,56
|
||||
771,84
|
||||
465,501
|
||||
1151,675
|
||||
1151,735
|
||||
981,752
|
||||
1222,714
|
||||
218,845
|
||||
1088,707
|
||||
249,775
|
||||
54,341
|
||||
423,246
|
||||
1161,246
|
||||
1181,508
|
||||
644,116
|
||||
58,114
|
||||
160,128
|
||||
843,667
|
||||
872,831
|
||||
202,477
|
||||
909,397
|
||||
1292,522
|
||||
33,371
|
||||
669,200
|
||||
1265,409
|
||||
529,672
|
||||
395,337
|
||||
512,282
|
||||
331,786
|
||||
1048,581
|
||||
1161,453
|
||||
261,64
|
||||
587,333
|
||||
443,654
|
||||
703,177
|
||||
1156,645
|
||||
1289,100
|
||||
692,434
|
||||
141,565
|
||||
517,282
|
||||
436,840
|
||||
679,648
|
||||
825,372
|
||||
174,75
|
||||
249,352
|
||||
438,7
|
||||
3,670
|
||||
169,522
|
||||
331,108
|
||||
766,231
|
||||
1014,585
|
||||
1133,453
|
||||
965,40
|
||||
887,246
|
||||
1289,292
|
||||
716,835
|
||||
421,619
|
||||
1263,772
|
||||
226,794
|
||||
500,649
|
||||
962,609
|
||||
1079,66
|
||||
731,255
|
||||
1156,494
|
||||
677,100
|
||||
175,700
|
||||
423,648
|
||||
10,115
|
||||
1014,887
|
||||
577,343
|
||||
218,859
|
||||
60,59
|
||||
760,114
|
||||
93,364
|
||||
607,177
|
||||
224,241
|
||||
800,746
|
||||
1126,218
|
||||
617,670
|
||||
1210,100
|
||||
358,119
|
||||
159,159
|
||||
932,247
|
||||
1201,290
|
||||
115,834
|
||||
10,779
|
||||
1274,12
|
||||
1250,506
|
||||
259,285
|
||||
428,436
|
||||
565,497
|
||||
333,708
|
||||
979,672
|
||||
587,66
|
||||
1221,815
|
||||
289,448
|
||||
1290,733
|
||||
130,772
|
||||
503,835
|
||||
1300,331
|
||||
792,56
|
||||
604,455
|
||||
259,330
|
||||
749,723
|
||||
191,761
|
||||
1094,511
|
||||
189,185
|
||||
1043,154
|
||||
474,469
|
||||
793,612
|
||||
246,298
|
||||
383,569
|
||||
276,199
|
||||
537,37
|
||||
467,227
|
||||
795,219
|
||||
1273,180
|
||||
1091,793
|
||||
907,479
|
||||
1280,775
|
||||
917,830
|
||||
495,431
|
||||
868,184
|
||||
1235,450
|
||||
1309,142
|
||||
157,820
|
||||
402,322
|
||||
3,137
|
||||
470,429
|
||||
167,780
|
||||
1195,882
|
||||
1069,250
|
||||
775,782
|
||||
1256,616
|
||||
428,100
|
||||
333,71
|
||||
663,845
|
||||
797,100
|
||||
604,838
|
||||
390,381
|
||||
738,579
|
||||
174,584
|
||||
88,42
|
||||
768,23
|
||||
1222,266
|
||||
1169,789
|
||||
887,648
|
||||
681,196
|
||||
325,388
|
||||
238,378
|
||||
316,106
|
||||
43,693
|
||||
551,154
|
||||
984,63
|
||||
1260,617
|
||||
430,138
|
||||
671,820
|
||||
918,357
|
||||
1094,383
|
||||
1069,756
|
||||
75,639
|
||||
599,246
|
||||
856,476
|
||||
117,81
|
||||
546,75
|
||||
1292,346
|
||||
1059,220
|
||||
8,400
|
||||
1225,644
|
||||
279,93
|
||||
979,338
|
||||
626,719
|
||||
1203,623
|
||||
594,220
|
||||
1248,848
|
||||
325,864
|
||||
995,163
|
||||
874,840
|
||||
1049,88
|
||||
954,175
|
||||
282,217
|
||||
132,51
|
||||
269,358
|
||||
1180,72
|
||||
10,563
|
||||
821,254
|
||||
872,511
|
||||
137,282
|
||||
820,717
|
||||
296,134
|
||||
1078,457
|
||||
634,733
|
||||
21,546
|
||||
1121,424
|
||||
26,614
|
||||
599,648
|
||||
1133,441
|
||||
110,131
|
||||
604,199
|
||||
1094,215
|
||||
565,602
|
||||
490,717
|
||||
748,198
|
||||
132,843
|
||||
279,528
|
||||
874,54
|
||||
257,17
|
||||
254,597
|
||||
666,312
|
||||
552,418
|
||||
518,56
|
||||
1223,351
|
||||
273,532
|
||||
1302,400
|
||||
858,865
|
||||
1001,854
|
||||
483,826
|
||||
82,717
|
||||
1181,221
|
||||
792,35
|
||||
592,446
|
||||
1130,469
|
||||
741,308
|
||||
649,260
|
||||
552,308
|
||||
100,100
|
||||
706,838
|
||||
211,464
|
||||
1051,816
|
||||
60,58
|
||||
234,198
|
||||
880,756
|
||||
927,325
|
||||
115,434
|
||||
487,791
|
||||
971,507
|
||||
1136,584
|
||||
736,746
|
||||
341,109
|
||||
845,424
|
||||
1069,519
|
||||
985,416
|
||||
599,394
|
||||
845,173
|
||||
708,406
|
||||
915,330
|
||||
1151,159
|
||||
393,382
|
||||
1052,826
|
||||
279,308
|
||||
633,348
|
||||
1042,28
|
||||
952,619
|
||||
36,882
|
||||
306,218
|
||||
565,815
|
||||
308,179
|
||||
1235,703
|
||||
241,519
|
||||
624,887
|
||||
306,161
|
||||
1248,46
|
||||
907,220
|
||||
47,810
|
||||
917,64
|
||||
895,556
|
||||
489,254
|
||||
132,275
|
||||
530,641
|
||||
887,340
|
||||
1149,192
|
||||
100,222
|
||||
656,635
|
||||
515,443
|
||||
47,177
|
||||
216,831
|
||||
910,597
|
||||
594,28
|
||||
1004,161
|
||||
691,128
|
||||
555,567
|
||||
815,667
|
||||
947,570
|
||||
50,166
|
||||
703,625
|
||||
882,100
|
||||
1066,406
|
||||
629,196
|
||||
1307,222
|
||||
542,23
|
||||
1284,614
|
||||
681,532
|
||||
744,516
|
||||
1178,582
|
||||
729,721
|
||||
979,891
|
||||
987,168
|
||||
1123,3
|
||||
438,35
|
||||
1143,562
|
||||
1136,620
|
||||
518,635
|
||||
867,878
|
||||
1056,326
|
||||
1222,42
|
||||
1223,543
|
||||
684,719
|
||||
301,644
|
||||
1141,522
|
||||
975,87
|
||||
288,564
|
||||
231,66
|
||||
517,43
|
||||
1146,152
|
||||
1034,393
|
||||
117,37
|
||||
585,250
|
||||
218,840
|
||||
751,609
|
||||
706,473
|
||||
686,327
|
||||
99,637
|
||||
1310,738
|
||||
361,660
|
||||
853,834
|
||||
1146,287
|
||||
1031,756
|
||||
189,173
|
||||
760,259
|
||||
470,836
|
||||
495,735
|
||||
995,387
|
||||
53,7
|
||||
897,644
|
||||
1169,565
|
||||
915,609
|
||||
241,71
|
||||
922,243
|
||||
3,56
|
||||
644,115
|
||||
756,212
|
||||
841,117
|
||||
1071,108
|
||||
927,121
|
||||
758,418
|
||||
1061,119
|
||||
577,256
|
||||
607,756
|
||||
913,877
|
||||
413,263
|
||||
1284,240
|
||||
440,507
|
||||
378,647
|
||||
331,215
|
||||
743,338
|
||||
132,619
|
||||
887,514
|
||||
18,148
|
||||
353,810
|
||||
805,246
|
||||
1077,619
|
||||
1284,707
|
||||
773,81
|
||||
279,756
|
||||
1051,778
|
||||
1086,620
|
||||
36,12
|
||||
452,865
|
||||
512,612
|
||||
87,351
|
||||
865,633
|
||||
761,568
|
||||
600,553
|
||||
1161,694
|
||||
433,886
|
||||
810,693
|
||||
1072,516
|
||||
971,731
|
||||
915,816
|
||||
82,635
|
||||
1158,143
|
||||
438,63
|
||||
1235,655
|
||||
1300,470
|
||||
1228,574
|
||||
390,894
|
||||
331,891
|
||||
1051,557
|
||||
1126,465
|
||||
136,56
|
||||
677,5
|
||||
62,46
|
||||
189,823
|
||||
189,424
|
||||
502,303
|
||||
216,859
|
||||
1014,134
|
||||
607,737
|
||||
69,17
|
||||
915,557
|
||||
107,719
|
||||
1171,675
|
||||
569,308
|
||||
304,707
|
||||
539,834
|
||||
510,298
|
||||
405,352
|
||||
1125,826
|
||||
544,231
|
||||
1019,772
|
||||
574,381
|
||||
88,714
|
||||
1169,548
|
||||
830,283
|
||||
231,609
|
||||
249,750
|
||||
874,397
|
||||
601,362
|
||||
599,500
|
||||
154,245
|
||||
|
||||
fold along x=655
|
||||
fold along y=447
|
||||
fold along x=327
|
||||
fold along y=223
|
||||
fold along x=163
|
||||
fold along y=111
|
||||
fold along x=81
|
||||
fold along y=55
|
||||
fold along x=40
|
||||
fold along y=27
|
||||
fold along y=13
|
||||
fold along y=6
|
|
@ -1,2 +0,0 @@
|
|||
2068
|
||||
2158894777814
|
|
@ -1,102 +0,0 @@
|
|||
KFFNFNNBCNOBCNPFVKCP
|
||||
|
||||
PB -> F
|
||||
KC -> F
|
||||
OB -> H
|
||||
HV -> N
|
||||
FS -> S
|
||||
CK -> K
|
||||
CC -> V
|
||||
HF -> K
|
||||
VP -> C
|
||||
CP -> S
|
||||
HO -> N
|
||||
OS -> N
|
||||
HS -> O
|
||||
HB -> F
|
||||
OH -> V
|
||||
PP -> B
|
||||
BS -> N
|
||||
VS -> F
|
||||
CN -> B
|
||||
KB -> O
|
||||
KH -> B
|
||||
SS -> K
|
||||
NS -> B
|
||||
BP -> V
|
||||
FB -> S
|
||||
PV -> O
|
||||
NB -> S
|
||||
FC -> F
|
||||
VB -> P
|
||||
PC -> O
|
||||
VF -> K
|
||||
BV -> K
|
||||
OO -> B
|
||||
PN -> N
|
||||
NH -> H
|
||||
SP -> B
|
||||
KF -> O
|
||||
BN -> F
|
||||
OF -> C
|
||||
VV -> H
|
||||
BB -> P
|
||||
KN -> H
|
||||
PO -> C
|
||||
BH -> O
|
||||
HC -> B
|
||||
VO -> O
|
||||
FV -> B
|
||||
PK -> V
|
||||
KO -> H
|
||||
BK -> V
|
||||
SC -> S
|
||||
KV -> B
|
||||
OV -> S
|
||||
HK -> F
|
||||
NP -> V
|
||||
VH -> P
|
||||
OK -> S
|
||||
SO -> C
|
||||
PF -> C
|
||||
SH -> N
|
||||
FP -> V
|
||||
CS -> C
|
||||
HH -> O
|
||||
KK -> P
|
||||
BF -> S
|
||||
NN -> O
|
||||
OC -> C
|
||||
CB -> O
|
||||
BO -> V
|
||||
ON -> F
|
||||
BC -> P
|
||||
NO -> N
|
||||
KS -> H
|
||||
FF -> V
|
||||
FN -> V
|
||||
HP -> N
|
||||
VC -> F
|
||||
OP -> K
|
||||
VN -> S
|
||||
NV -> F
|
||||
SV -> F
|
||||
FO -> V
|
||||
PS -> H
|
||||
VK -> O
|
||||
PH -> P
|
||||
NF -> N
|
||||
KP -> S
|
||||
CF -> S
|
||||
FK -> P
|
||||
FH -> F
|
||||
CO -> H
|
||||
SN -> B
|
||||
NC -> H
|
||||
SK -> P
|
||||
CV -> P
|
||||
CH -> H
|
||||
HN -> N
|
||||
SB -> H
|
||||
NK -> B
|
||||
SF -> H
|
|
@ -1,2 +0,0 @@
|
|||
904
|
||||
200476472872
|
|
@ -1 +0,0 @@
|
|||
20546C8802538E136091C1802689BCD7DA45948D319D1B100747A009C97696E8B4ABFCA6AB8F4F26C401964A6271C80F802D392C01CEDDCE6E5CB829802F600A00021B14E34C361006E0AC418BB2CA6800BE4599BB6A73507002A52BEEB14D201802F600849E64D3369D37C74100866785B3D0ADFD8E601E5EB9DE2366D93ECB8B040142CB8ACE07CCB5CF34CA89380410B6134CE6FEF104A2B200243396976A00401A45004313D68435DBDDDA61CE6428C01491AEBF0C7E580AE00CCC401B86514216880370EE3443D2013DF003750004361343D88800084C4C8B116A679018300740010C8571BA32080350DA0D42800043A3044189AE0174B314D76E1F3ACF3BDAE3EE7298FF134002EF9DBCD0644127E3CAE7FCBA9A80393544F9A927C973DF1A500965A5CEA94C4DDA5658B94C6C3002A798A629CF21280532BAB4F4C7271E45EE6E71D8143A9BC7948804AB94D1D6006AC200EC1E8A10C00010985316A35C3620061E641644D661A4C012993E99208FC60097802F28F528F738606008CA47205400814C89CC8890064D400AB4BE0A66F2BF253E73AE8401424A7BFB16C0037E06CE0641E0013B08010A8930CE2B980351161DC3730066274188B020054A5E16965940057895ADEB5BF56A635ADE2354191D70566273A6F5B078266008D8022200D46E8291C4401A8CF0CE33CEDE55E9F9802BA00B4BD44A5EA2D10CC00B40316800BAE1003580A6D6026F00090E50024007C9500258068850035C00A4012ED8040B400D71002AF500284009700226336CA4980471D655E25D4650888023AB00525CAE5CBA5E428600BE003993778CB4732996E9887AE3F311C291004BD37517C0041E780A7808802AF8C1C00D0CDBE4ACAD69B3B004E13BDF23CAE7368C9F62448F64546008E0034F3720192A67AD9254917454200DCE801C99ADF182575BBAACAC7F8580
|
|
@ -1,2 +0,0 @@
|
|||
1714680
|
||||
1963088820
|
1000
2021/data/day2.input
1000
2021/data/day2.input
File diff suppressed because it is too large
Load diff
|
@ -1,2 +0,0 @@
|
|||
642125
|
||||
1235164413198198
|
|
@ -1,420 +0,0 @@
|
|||
on x=-31..15,y=-40..12,z=-21..27
|
||||
on x=-11..41,y=-15..37,z=-2..45
|
||||
on x=-9..43,y=-19..30,z=-23..27
|
||||
on x=-36..11,y=0..47,z=-38..16
|
||||
on x=-36..18,y=-43..8,z=-4..47
|
||||
on x=-2..48,y=-5..39,z=-15..32
|
||||
on x=-25..24,y=-1..45,z=-38..15
|
||||
on x=-15..38,y=-49..-4,z=-29..23
|
||||
on x=-29..18,y=-20..31,z=-6..47
|
||||
on x=-37..15,y=0..47,z=-17..32
|
||||
off x=-23..-9,y=-7..9,z=5..18
|
||||
on x=-9..40,y=4..49,z=-41..13
|
||||
off x=14..23,y=25..37,z=-20..-9
|
||||
on x=-34..16,y=-44..9,z=-5..42
|
||||
off x=-25..-10,y=-37..-22,z=4..18
|
||||
on x=-48..6,y=-37..9,z=-40..7
|
||||
off x=5..17,y=14..30,z=-6..4
|
||||
on x=-19..30,y=-49..3,z=-10..41
|
||||
off x=-22..-9,y=22..37,z=-31..-14
|
||||
on x=-42..7,y=-29..21,z=-13..37
|
||||
on x=-16268..-2761,y=73412..85556,z=-24609..-14482
|
||||
on x=33763..42040,y=-61278..-43675,z=21918..43169
|
||||
on x=-25200..-2112,y=-51420..-47840,z=47019..59882
|
||||
on x=37923..50058,y=31838..54160,z=-57601..-34479
|
||||
on x=-30620..-24353,y=-79285..-68074,z=-2977..19356
|
||||
on x=-30609..1452,y=-36514..-15009,z=66859..79332
|
||||
on x=-24742..-5853,y=-43809..-14427,z=-90382..-58759
|
||||
on x=-13668..16445,y=-22841..10989,z=73406..93540
|
||||
on x=28389..52072,y=-26968..-2267,z=-79598..-66367
|
||||
on x=27980..54406,y=38341..66509,z=32093..36649
|
||||
on x=59985..65276,y=-66708..-27188,z=-19249..-2151
|
||||
on x=41844..68956,y=-63008..-37128,z=520..24655
|
||||
on x=71804..95178,y=-15814..14606,z=-7097..17816
|
||||
on x=17765..28889,y=-15081..18428,z=74594..86403
|
||||
on x=27379..42566,y=-27124..-9082,z=-80345..-63942
|
||||
on x=-81191..-59873,y=37629..56626,z=-33772..-13190
|
||||
on x=26251..50978,y=61655..81765,z=5174..41787
|
||||
on x=3545..20418,y=76124..91387,z=10429..18016
|
||||
on x=-56569..-43421,y=43007..48697,z=-39789..-16431
|
||||
on x=-8898..20972,y=-75311..-68277,z=26037..31459
|
||||
on x=-82974..-55962,y=-31904..-12744,z=-19880..-177
|
||||
on x=21759..46201,y=4896..27986,z=-79014..-52022
|
||||
on x=-72845..-54454,y=-46732..-31354,z=-3518..9682
|
||||
on x=48077..69306,y=48471..78577,z=-24376..10791
|
||||
on x=-89235..-75432,y=-23559..-11282,z=2849..29606
|
||||
on x=-19648..5187,y=-28801..1547,z=67705..87729
|
||||
on x=-36677..-11208,y=-52582..-29826,z=-75754..-54460
|
||||
on x=52967..71480,y=-32156..-13028,z=40031..57490
|
||||
on x=-9670..14112,y=-86845..-72969,z=21041..37167
|
||||
on x=-23506..-2008,y=14436..39569,z=-74893..-62468
|
||||
on x=60265..81466,y=-9195..22677,z=-31963..-24825
|
||||
on x=62518..78007,y=-28080..803,z=18055..36364
|
||||
on x=-67871..-58556,y=-17100..7434,z=-53150..-44051
|
||||
on x=-21869..-7545,y=56607..78795,z=42300..59289
|
||||
on x=8133..26370,y=59453..76378,z=24987..46061
|
||||
on x=-78155..-54530,y=40318..64112,z=-11319..19884
|
||||
on x=-49937..-29803,y=-73977..-61214,z=-11264..11122
|
||||
on x=-84215..-59040,y=-24340..-8768,z=22605..36340
|
||||
on x=-72333..-46667,y=-20261..-1550,z=33007..49989
|
||||
on x=-87051..-55751,y=-39773..-27347,z=-28982..-4905
|
||||
on x=-53210..-37633,y=-57897..-36246,z=-34954..-20198
|
||||
on x=59340..84949,y=33575..44982,z=-28334..-9464
|
||||
on x=49948..66289,y=693..18345,z=56235..63720
|
||||
on x=-26265..-11787,y=-75180..-61895,z=-51729..-26447
|
||||
on x=46656..68506,y=17462..39678,z=28004..35033
|
||||
on x=-5095..20428,y=-65178..-43905,z=-76055..-52443
|
||||
on x=-6031..4325,y=-29275..-8056,z=-84181..-59830
|
||||
on x=57442..76188,y=-22259..8793,z=-55480..-45690
|
||||
on x=26301..43633,y=-49717..-38698,z=48660..65868
|
||||
on x=-20883..3324,y=30657..66848,z=57545..79329
|
||||
on x=-94467..-58613,y=-26697..762,z=16196..39574
|
||||
on x=8005..42105,y=-45637..-22315,z=-74968..-51548
|
||||
on x=-48966..-25366,y=32223..45945,z=32542..62201
|
||||
on x=-69017..-46223,y=21802..42755,z=-52315..-45517
|
||||
on x=14071..21029,y=-27684..-3889,z=-82302..-69903
|
||||
on x=-35310..-14611,y=-69343..-52273,z=29582..57259
|
||||
on x=-47733..-43614,y=41650..76018,z=-43518..-5378
|
||||
on x=36045..54586,y=-63874..-55437,z=27809..45401
|
||||
on x=-23706..-7340,y=37745..58874,z=-74869..-50604
|
||||
on x=-34375..-8490,y=-24045..-7424,z=-90288..-67864
|
||||
on x=71187..79617,y=8420..18536,z=16022..39405
|
||||
on x=-28965..-8258,y=43254..58521,z=-50330..-35686
|
||||
on x=-29861..-22121,y=-62714..-58881,z=41404..55839
|
||||
on x=36839..51186,y=-72064..-50522,z=-40820..-12348
|
||||
on x=-80940..-56434,y=-36366..-6238,z=-25989..-1570
|
||||
on x=16090..44431,y=-70714..-53053,z=-48187..-24318
|
||||
on x=-57784..-35812,y=-55762..-21328,z=-61669..-40202
|
||||
on x=-1153..27210,y=-72257..-57105,z=-52729..-43034
|
||||
on x=36045..52956,y=40739..63305,z=-40612..-35470
|
||||
on x=-37386..-27602,y=-73787..-66457,z=5859..16937
|
||||
on x=22605..24957,y=-35007..374,z=-88037..-74742
|
||||
on x=69972..91356,y=-21820..1332,z=-33615..-20343
|
||||
on x=3152..34491,y=8121..32288,z=-92170..-58629
|
||||
on x=-68865..-45677,y=-44049..-16100,z=-48316..-43901
|
||||
on x=54057..68453,y=-47451..-23433,z=-45583..-29267
|
||||
on x=56843..78547,y=10609..34067,z=1987..32520
|
||||
on x=588..27816,y=46724..64149,z=-67994..-30736
|
||||
on x=39268..59592,y=-75776..-42781,z=10976..37943
|
||||
on x=-4319..20271,y=-85842..-61203,z=-28175..1591
|
||||
on x=-20482..8670,y=-85390..-59726,z=-23552..-7304
|
||||
on x=20197..35773,y=-33819..-21770,z=54097..85103
|
||||
on x=-70270..-59947,y=-49234..-26582,z=-11572..7062
|
||||
on x=-88326..-54246,y=-41068..-25234,z=-22529..1368
|
||||
on x=-21643..-18556,y=-29486..-7870,z=56613..83150
|
||||
on x=-57648..-53221,y=24878..37305,z=28112..47953
|
||||
on x=50871..57090,y=-50882..-28901,z=-47823..-41828
|
||||
on x=3603..33598,y=50068..62701,z=-68639..-46682
|
||||
on x=37694..58917,y=-81338..-55339,z=-6294..11393
|
||||
on x=-1419..9336,y=-75338..-64874,z=43272..59331
|
||||
on x=62900..95797,y=10309..30061,z=-17622..5010
|
||||
on x=20359..33467,y=-80058..-55327,z=-44618..-17466
|
||||
on x=73162..85481,y=-18674..9179,z=27632..30040
|
||||
on x=-12072..7247,y=-68569..-44935,z=38996..69461
|
||||
on x=-14910..2438,y=-66748..-59496,z=-62451..-43733
|
||||
on x=-55491..-33270,y=-80513..-50398,z=-5725..27700
|
||||
on x=-43858..-25913,y=-33078..-20894,z=-75887..-49681
|
||||
on x=-39184..-11369,y=-77771..-38776,z=-60846..-42774
|
||||
on x=-43965..-25005,y=52823..70376,z=29934..48535
|
||||
on x=11832..27831,y=38503..62279,z=-67375..-46855
|
||||
on x=-86659..-58572,y=-52574..-20758,z=-5049..-1380
|
||||
on x=-20079..-971,y=-88952..-66624,z=-790..16273
|
||||
on x=9364..33049,y=70116..96061,z=-666..28174
|
||||
on x=24090..54224,y=-31038..-8920,z=-62258..-49312
|
||||
on x=-4796..22630,y=59190..90127,z=-27512..4087
|
||||
on x=58927..78681,y=25203..57439,z=12551..35835
|
||||
on x=43802..62336,y=-10602..-563,z=-65831..-50707
|
||||
on x=49802..62635,y=-35757..-12707,z=38263..62005
|
||||
on x=14375..27850,y=36589..73868,z=46321..51160
|
||||
on x=30926..56823,y=64082..85345,z=8399..26595
|
||||
on x=26138..34222,y=-74916..-64576,z=12585..20349
|
||||
on x=49268..64536,y=55554..56931,z=8266..30603
|
||||
on x=63783..70255,y=-43725..-37221,z=-5402..21946
|
||||
on x=-25851..-10388,y=-44145..-23573,z=70787..81764
|
||||
on x=-2308..30385,y=-77664..-65487,z=10624..27974
|
||||
on x=30629..51160,y=-67708..-48630,z=-11628..-5521
|
||||
on x=-28371..2765,y=47468..62783,z=37378..63850
|
||||
on x=-54181..-47351,y=41114..72671,z=-12142..22919
|
||||
on x=232..29443,y=38022..65125,z=-70975..-51690
|
||||
on x=-89818..-61775,y=9402..22079,z=11379..27812
|
||||
on x=-46655..-36075,y=-73368..-46204,z=-55433..-32265
|
||||
on x=59126..83817,y=39122..61516,z=-17994..1532
|
||||
on x=26714..58440,y=11528..27094,z=48759..75861
|
||||
on x=-35914..-20622,y=59856..73765,z=4589..24238
|
||||
on x=18259..28451,y=-80578..-53971,z=-33788..-10461
|
||||
on x=-47217..-34327,y=70275..79914,z=-8079..24768
|
||||
on x=-76192..-60391,y=35036..63981,z=-15347..380
|
||||
on x=-63732..-48024,y=-54229..-26661,z=-42450..-31348
|
||||
on x=-23519..-7950,y=-75513..-50765,z=-63008..-35282
|
||||
on x=19475..32136,y=-21295..-15326,z=53823..77193
|
||||
on x=-25139..-22008,y=-19696..13946,z=-92401..-59350
|
||||
on x=-95951..-61878,y=-26133..-1879,z=-33703..-9810
|
||||
on x=68912..89523,y=-23734..-8320,z=-16650..4655
|
||||
on x=-65750..-56515,y=20184..33335,z=-45037..-33283
|
||||
on x=7158..15863,y=-41827..-7665,z=-75732..-73496
|
||||
on x=-60484..-42124,y=-51494..-23379,z=-57680..-35254
|
||||
on x=55653..83430,y=23940..45283,z=-15684..-14212
|
||||
on x=-10251..13694,y=-33345..-12875,z=67504..86459
|
||||
on x=21776..31354,y=-37486..-19956,z=46923..77653
|
||||
on x=75980..83400,y=-1819..19149,z=-21085..-2030
|
||||
on x=-61751..-41543,y=-5188..6299,z=-83815..-58294
|
||||
on x=-7338..6665,y=36157..44741,z=52925..81174
|
||||
on x=52861..67716,y=-7373..30136,z=39315..71237
|
||||
on x=13050..29744,y=66525..87545,z=1771..37491
|
||||
on x=-64733..-39640,y=25254..52987,z=-50910..-32439
|
||||
on x=63635..81414,y=-22871..-4335,z=7646..28763
|
||||
on x=40134..58126,y=-11172..9476,z=-66912..-54215
|
||||
on x=-86522..-66364,y=-33752..-15969,z=-23363..-13273
|
||||
on x=35479..45095,y=69971..73604,z=8910..26850
|
||||
on x=-43268..-15119,y=-66053..-38869,z=39592..46963
|
||||
on x=-21710..8680,y=40705..71234,z=41360..73209
|
||||
on x=13940..22553,y=36324..58196,z=-77382..-53080
|
||||
on x=23434..50783,y=-39817..-28342,z=-69110..-48877
|
||||
on x=73507..85343,y=-11561..15539,z=-14495..-4774
|
||||
on x=-54941..-37724,y=-13576..1478,z=40440..68801
|
||||
on x=43643..68451,y=-10135..662,z=-59531..-39039
|
||||
on x=-24211..-6108,y=50759..72990,z=-62513..-37860
|
||||
on x=26879..61822,y=35613..67902,z=38756..61459
|
||||
on x=-89359..-75327,y=-18589..-6663,z=-29014..7966
|
||||
on x=17380..33566,y=-58827..-49271,z=48108..66133
|
||||
on x=-2444..15010,y=-77969..-63710,z=29136..46467
|
||||
on x=-10818..6229,y=-29611..49,z=-81262..-75622
|
||||
on x=-6180..20035,y=74194..90454,z=-13495..1440
|
||||
on x=-35911..-13227,y=-57034..-29632,z=-69180..-52647
|
||||
on x=30009..49730,y=-64899..-52104,z=-61162..-27263
|
||||
on x=-78257..-48942,y=39217..54751,z=-29567..-20398
|
||||
on x=37168..46885,y=-80577..-52776,z=1014..37078
|
||||
on x=6944..29897,y=11577..21593,z=-82020..-59481
|
||||
on x=-31931..-238,y=-59356..-38875,z=-80342..-57991
|
||||
on x=-38801..-36538,y=2975..20673,z=65274..82670
|
||||
on x=63409..76122,y=132..19103,z=23941..40408
|
||||
on x=7732..23852,y=-19027..6940,z=75488..96064
|
||||
on x=-64444..-45808,y=11443..29434,z=35964..59523
|
||||
on x=18285..35633,y=49509..72903,z=12689..35798
|
||||
on x=-2949..17519,y=-53956..-31139,z=55058..81542
|
||||
on x=-32888..-12204,y=-63545..-52688,z=43909..52128
|
||||
on x=-1703..19447,y=-84815..-69925,z=-32435..-19742
|
||||
on x=-69069..-40979,y=37136..49391,z=-47586..-29945
|
||||
on x=59756..80566,y=-42821..-20427,z=25880..40675
|
||||
on x=6051..36400,y=-86187..-61812,z=-47296..-31890
|
||||
on x=59071..84052,y=-14966..16336,z=17686..36159
|
||||
on x=-38604..-32778,y=2520..36999,z=-81989..-67215
|
||||
on x=66925..78543,y=2308..22047,z=-39005..-19664
|
||||
on x=-34989..-8703,y=57308..62622,z=40005..48549
|
||||
on x=-52811..-31203,y=55877..66260,z=14153..36886
|
||||
on x=-45389..-12954,y=-3730..12116,z=-79157..-69961
|
||||
on x=-23789..-13770,y=-66812..-61018,z=-52957..-23785
|
||||
on x=13853..39791,y=60431..80042,z=28663..46404
|
||||
on x=-24898..-4124,y=15057..34896,z=-86489..-68066
|
||||
on x=-95271..-73643,y=-8281..-2302,z=5269..33970
|
||||
on x=-22180..1312,y=-32828..-22422,z=-80345..-65642
|
||||
on x=-49902..-20843,y=-11615..-5264,z=67929..77434
|
||||
on x=-54310..-39323,y=-32495..-6462,z=39239..66258
|
||||
on x=-20031..4022,y=50563..64702,z=44178..65613
|
||||
on x=-5460..17220,y=69479..82968,z=-93..26732
|
||||
on x=51905..72078,y=11383..28169,z=-49180..-26809
|
||||
on x=59045..74424,y=-49404..-32586,z=2822..38387
|
||||
on x=16110..37775,y=-15152..-5485,z=66144..82152
|
||||
on x=16153..31577,y=64109..79966,z=7957..34548
|
||||
on x=-73616..-46114,y=-41730..-10806,z=-42377..-34184
|
||||
on x=-21820..-2194,y=-82802..-47511,z=-61692..-29261
|
||||
on x=30857..38250,y=13048..40418,z=62640..79760
|
||||
on x=-4023..5491,y=23358..43076,z=-81952..-57807
|
||||
off x=-11417..16910,y=-6421..9542,z=-87766..-68468
|
||||
off x=-80140..-59258,y=-44626..-28936,z=12903..45896
|
||||
off x=31942..46811,y=-29583..-24759,z=-67482..-49237
|
||||
off x=18831..43507,y=34731..49397,z=-66558..-57490
|
||||
on x=-83682..-74692,y=-19795..-8370,z=4365..8081
|
||||
on x=-73723..-48408,y=-41872..-17170,z=25850..39928
|
||||
off x=-17905..-13154,y=-54510..-44611,z=-79922..-50706
|
||||
off x=43753..68220,y=37781..49568,z=35107..63486
|
||||
on x=19144..48501,y=27352..55966,z=52211..71545
|
||||
on x=-68916..-50993,y=23610..43473,z=-35659..-22034
|
||||
off x=-68708..-41208,y=50547..59778,z=-27505..-3997
|
||||
off x=7976..32867,y=-64128..-52351,z=43125..51405
|
||||
on x=7398..44110,y=-77989..-55830,z=-44794..-10674
|
||||
off x=31543..59409,y=-59240..-49161,z=5888..22465
|
||||
on x=-60924..-35763,y=5263..31909,z=-67060..-38563
|
||||
off x=-46172..-25986,y=9684..20405,z=-74193..-53096
|
||||
off x=-45030..-31272,y=49282..85688,z=-2147..16292
|
||||
on x=-38198..-30030,y=-18830..8264,z=-82459..-62924
|
||||
on x=25881..50501,y=38243..41409,z=-74137..-53637
|
||||
off x=-75825..-51662,y=-28841..-1241,z=46043..72226
|
||||
off x=23071..31413,y=-66262..-31252,z=-58336..-46372
|
||||
off x=-65459..-43357,y=-71892..-47149,z=-7491..9113
|
||||
off x=-11687..1834,y=-96323..-70268,z=-8442..-5013
|
||||
off x=-98284..-75029,y=-13336..-469,z=-19639..-6647
|
||||
off x=-78119..-77515,y=-17038..2730,z=-20329..-12884
|
||||
on x=-11010..-282,y=68385..78119,z=19107..32396
|
||||
off x=-18969..8580,y=-41228..-16323,z=64960..92107
|
||||
on x=-30756..-9890,y=-77149..-74431,z=-16951..5536
|
||||
on x=-1351..23521,y=34166..54033,z=-77118..-56805
|
||||
off x=-41422..-2879,y=-39662..-25879,z=59642..72173
|
||||
on x=-15189..7542,y=-78696..-58288,z=-53881..-21661
|
||||
on x=-49875..-36660,y=42475..71985,z=-60886..-29856
|
||||
off x=-33364..-243,y=51633..74148,z=-65820..-47122
|
||||
off x=-13052..-438,y=-50291..-20306,z=64409..89480
|
||||
off x=18797..30805,y=-61435..-29538,z=50927..72456
|
||||
off x=-535..14954,y=-61772..-56234,z=42949..68543
|
||||
off x=-61282..-28853,y=-79862..-64935,z=-5191..8964
|
||||
on x=56833..82783,y=-5520..4690,z=-30238..-11759
|
||||
off x=-48706..-29743,y=57961..88993,z=-26662..-13726
|
||||
on x=-43753..-34836,y=45812..61088,z=-65900..-33088
|
||||
on x=-34742..-12464,y=58565..88013,z=-10446..24279
|
||||
off x=-728..28432,y=61668..80130,z=9951..13996
|
||||
on x=-64953..-37238,y=8227..33992,z=-58763..-47419
|
||||
on x=-60137..-37631,y=-62412..-46421,z=12784..25044
|
||||
on x=39802..57534,y=46304..66897,z=9259..37972
|
||||
on x=33582..38897,y=21300..32768,z=-69411..-63580
|
||||
on x=54101..74684,y=-43691..-32515,z=-48214..-21217
|
||||
on x=34443..47444,y=-38846..-17489,z=-79439..-44037
|
||||
on x=26422..47943,y=-79544..-59532,z=-35194..-23693
|
||||
on x=-27931..-4214,y=-41718..-37376,z=-71336..-56845
|
||||
off x=-13025..12948,y=-9674..12098,z=61220..97279
|
||||
off x=-71283..-56740,y=37883..60739,z=-32264..-4311
|
||||
on x=-43113..-28486,y=-71249..-57817,z=-45405..-28013
|
||||
off x=-32103..-9810,y=15842..24298,z=61423..87642
|
||||
off x=-17927..-13972,y=-28844..-4847,z=-82475..-61095
|
||||
off x=-5141..32816,y=-78393..-65416,z=-44689..-25883
|
||||
on x=-14630..-226,y=-69465..-44081,z=-59199..-46219
|
||||
on x=52453..72679,y=45237..64743,z=6061..39421
|
||||
on x=-39673..-18265,y=-27573..-21807,z=68883..74631
|
||||
off x=13079..24968,y=-48786..-26712,z=50948..66164
|
||||
on x=41137..68193,y=20634..26236,z=-62237..-37673
|
||||
off x=44473..74640,y=-41075..-29282,z=-48434..-34835
|
||||
off x=2596..18042,y=-72490..-53937,z=43432..63623
|
||||
off x=-79387..-46432,y=-59253..-35215,z=17915..21092
|
||||
off x=-45378..-28774,y=-82320..-60579,z=-20033..5755
|
||||
off x=-63078..-39995,y=56467..70582,z=-12429..7923
|
||||
on x=56299..89046,y=16079..35370,z=1047..27734
|
||||
off x=-73191..-62162,y=-10709..9255,z=31945..60769
|
||||
on x=-92647..-73976,y=11508..44122,z=-10968..11288
|
||||
on x=39283..50439,y=41452..75957,z=-44781..-17165
|
||||
off x=-78580..-40455,y=-47032..-23251,z=35679..53864
|
||||
off x=-35818..-15180,y=-60785..-44040,z=-56896..-32871
|
||||
on x=-12403..19634,y=-37806..-28714,z=60466..92315
|
||||
off x=-6584..14637,y=11601..32479,z=55981..82418
|
||||
off x=3427..13895,y=62276..79635,z=-18569..-2036
|
||||
off x=-75299..-55430,y=-56438..-42843,z=-40463..-20313
|
||||
on x=-76382..-67609,y=-30159..-7158,z=-39763..-5641
|
||||
off x=-78234..-66014,y=-4072..19725,z=-48675..-20237
|
||||
off x=-17255..-1228,y=-79201..-62700,z=44411..52226
|
||||
off x=41222..49220,y=-535..24648,z=50814..79651
|
||||
on x=-17600..-2083,y=48656..69603,z=-72425..-53667
|
||||
on x=-36970..-7303,y=-66857..-59482,z=37238..43473
|
||||
on x=-35190..-15947,y=-8793..15350,z=67281..83539
|
||||
off x=-33724..-28506,y=25447..42128,z=-76662..-56726
|
||||
off x=-32909..-4673,y=70289..96002,z=-27988..-7725
|
||||
off x=-35004..-10651,y=-46859..-21224,z=53920..66920
|
||||
off x=48523..81631,y=6292..31267,z=-46628..-33235
|
||||
on x=-81724..-60210,y=-33056..-19672,z=12796..29093
|
||||
off x=14592..48270,y=514..16339,z=58375..85423
|
||||
off x=841..26514,y=54248..80990,z=32342..54694
|
||||
on x=962..22843,y=-74697..-48613,z=-43426..-33427
|
||||
off x=-33279..-3222,y=15542..21113,z=-76837..-66803
|
||||
off x=-70808..-46984,y=-26096..9606,z=-61364..-41726
|
||||
off x=56234..91300,y=-46828..-25584,z=-31699..-5452
|
||||
on x=7534..40696,y=39658..69911,z=-53349..-34492
|
||||
off x=-86975..-78519,y=5399..12876,z=-11594..9440
|
||||
on x=-37585..-14518,y=52841..72715,z=39495..59620
|
||||
off x=-91693..-64961,y=-4273..14662,z=19646..33512
|
||||
on x=29397..41835,y=-65015..-55284,z=-54315..-35308
|
||||
off x=-56584..-41152,y=-70640..-58464,z=-16220..4708
|
||||
on x=-34762..-16435,y=-45193..-41382,z=48897..72765
|
||||
on x=-67677..-49516,y=18763..37669,z=12179..36798
|
||||
on x=-55734..-36710,y=40109..63200,z=-4477..16097
|
||||
on x=-36457..-26044,y=-2522..27516,z=56581..77833
|
||||
on x=5866..29832,y=-88145..-59746,z=-8002..333
|
||||
on x=57071..78433,y=10868..32933,z=-19783..-1923
|
||||
off x=-20388..13468,y=-19002..-8309,z=69722..90287
|
||||
off x=-73111..-66678,y=-51011..-14796,z=-26146..-18176
|
||||
on x=-82713..-60890,y=-9594..16478,z=-43812..-16640
|
||||
off x=25158..48301,y=-13762..4215,z=-75170..-73703
|
||||
on x=-45132..-33935,y=50481..70678,z=12453..31598
|
||||
on x=-61810..-35560,y=56241..69920,z=-18251..3076
|
||||
on x=-57774..-49809,y=-34464..-16665,z=-54307..-38889
|
||||
off x=57437..67902,y=-11426..2673,z=36182..51645
|
||||
off x=-46056..-17171,y=15759..36036,z=56843..87869
|
||||
off x=-537..20736,y=-78316..-40547,z=-71989..-47572
|
||||
on x=-76615..-63688,y=-31204..-20452,z=-33164..-13158
|
||||
off x=-81259..-63064,y=4310..30972,z=-44477..-13230
|
||||
off x=1667..10220,y=-88640..-58969,z=21234..38278
|
||||
off x=-82764..-61291,y=-12966..18053,z=-34401..-15913
|
||||
on x=-830..23016,y=61029..84093,z=23471..32805
|
||||
off x=45182..82533,y=31670..41676,z=5034..34474
|
||||
on x=-79592..-60110,y=-28599..-10420,z=-15013..-13286
|
||||
on x=41629..66177,y=7273..39832,z=-70911..-46964
|
||||
on x=-24181..-2511,y=-14329..-8601,z=-87065..-71417
|
||||
on x=68393..82452,y=-15645..7133,z=-25044..-4167
|
||||
off x=-30452..5173,y=-90064..-64228,z=-33914..-16622
|
||||
off x=-46198..-38849,y=30435..44046,z=-75515..-42056
|
||||
on x=-3044..8360,y=-45702..-33159,z=48127..67169
|
||||
on x=-19716..12232,y=-16974..-1798,z=62956..80159
|
||||
off x=-8652..29525,y=50692..79736,z=-57953..-25988
|
||||
on x=-67010..-50436,y=-39075..-16212,z=46626..72496
|
||||
off x=-64360..-61888,y=35492..43270,z=-45633..-18851
|
||||
off x=63654..91168,y=-627..9752,z=-45387..-13299
|
||||
off x=-43687..-26223,y=47156..75205,z=-57949..-38000
|
||||
on x=28170..64143,y=-71780..-50371,z=27285..45866
|
||||
off x=75657..83623,y=7851..25102,z=5999..31863
|
||||
off x=-2378..4668,y=1860..24150,z=-89080..-70158
|
||||
off x=-28434..-20764,y=69532..82033,z=-18472..5260
|
||||
on x=31597..50173,y=36277..68351,z=-54327..-25222
|
||||
off x=-100..20288,y=-8018..18694,z=-81267..-61884
|
||||
on x=54540..70105,y=13276..23659,z=-64495..-26166
|
||||
off x=-65003..-37349,y=-50652..-32606,z=34817..43549
|
||||
on x=11484..29883,y=-46774..-24790,z=-86030..-61340
|
||||
off x=-16454..8894,y=32162..51804,z=-81832..-60183
|
||||
off x=-87478..-72787,y=-27530..486,z=-6079..8294
|
||||
on x=-15346..-1146,y=-81265..-52963,z=32335..51965
|
||||
on x=66676..84372,y=-23588..-3704,z=15224..16541
|
||||
on x=10118..32777,y=-27912..-10010,z=68364..93233
|
||||
on x=13508..28471,y=-69894..-45072,z=39827..67714
|
||||
on x=-16962..7480,y=62372..91811,z=-9568..19097
|
||||
on x=49730..78835,y=-29714..-4555,z=-52455..-30159
|
||||
off x=-41859..-23109,y=-19025..-85,z=73345..93699
|
||||
off x=-64287..-43719,y=38786..51643,z=15814..50351
|
||||
off x=-64017..-52686,y=-30352..-7910,z=-54269..-35636
|
||||
on x=-48526..-28820,y=-29275..-21681,z=46865..61454
|
||||
on x=-22984..3213,y=36151..57788,z=68972..81644
|
||||
off x=24698..42651,y=42537..58033,z=45292..64070
|
||||
on x=-60009..-43048,y=-19070..-6729,z=36715..57481
|
||||
on x=-39419..-11957,y=57676..88023,z=-90..14383
|
||||
on x=-69506..-45424,y=-12654..11191,z=-79962..-56241
|
||||
off x=-84033..-48665,y=-21630..-9445,z=36751..42536
|
||||
off x=33651..52330,y=21405..37083,z=61710..71195
|
||||
on x=13392..35413,y=-91558..-60952,z=-17591..6695
|
||||
on x=-30550..-21113,y=-85052..-50897,z=-35766..-32831
|
||||
on x=22488..34701,y=60517..77966,z=-20244..4275
|
||||
on x=12080..33217,y=-71597..-50737,z=-56565..-44719
|
||||
off x=-29548..-15673,y=27877..41300,z=-79958..-48987
|
||||
off x=-80390..-60613,y=20249..46361,z=19833..39996
|
||||
on x=46966..84089,y=34806..47552,z=-18458..15199
|
||||
off x=-9316..11741,y=68950..98330,z=-1520..13266
|
||||
off x=-29925..-9889,y=-75732..-50199,z=34533..57412
|
||||
on x=-7342..-2505,y=-85763..-59005,z=-35058..-25769
|
||||
on x=29951..56079,y=-81275..-52573,z=11804..26280
|
||||
on x=26737..50947,y=-64105..-53323,z=-55729..-21772
|
||||
off x=-3718..18877,y=38035..41002,z=-79957..-63481
|
||||
on x=-48088..-22962,y=42706..49143,z=52740..71769
|
||||
off x=-71945..-57818,y=-11524..17450,z=37744..63978
|
||||
on x=31524..44251,y=-4535..24563,z=58049..78765
|
||||
on x=-53219..-32237,y=-72853..-53335,z=28182..54957
|
||||
on x=-76635..-46440,y=23233..45049,z=16138..44117
|
||||
off x=-38607..-19026,y=-37271..-25530,z=-81333..-55983
|
||||
off x=-50145..-15369,y=16537..40806,z=-80796..-52898
|
||||
on x=-43832..-19086,y=-45673..-37583,z=42936..71282
|
||||
off x=-52699..-36375,y=20909..36727,z=32818..62015
|
||||
off x=73367..82103,y=-38351..-19664,z=-2996..14667
|
||||
on x=-30106..-16369,y=-57496..-36709,z=-62282..-40625
|
||||
on x=-40612..-21586,y=29772..54286,z=-65210..-55574
|
||||
on x=-21799..-6056,y=48843..67358,z=35525..59714
|
||||
off x=6461..31862,y=-41077..-21034,z=-82019..-56743
|
||||
off x=-16594..11056,y=-91484..-64770,z=11722..34592
|
||||
on x=41693..49612,y=44598..61980,z=-39833..-12014
|
||||
on x=67376..93098,y=23475..46194,z=3214..23673
|
||||
off x=-81794..-62247,y=14498..29313,z=-30333..-3880
|
||||
off x=31528..49103,y=63600..77967,z=21699..42370
|
||||
on x=40818..63504,y=-43305..-29947,z=36934..49512
|
||||
off x=-20193..-11713,y=35933..52262,z=-67731..-45077
|
||||
on x=-674..27030,y=-78658..-58562,z=-33828..-15369
|
|
@ -1,2 +0,0 @@
|
|||
3895776
|
||||
7928162
|
1000
2021/data/day3.input
1000
2021/data/day3.input
File diff suppressed because it is too large
Load diff
|
@ -1,2 +0,0 @@
|
|||
58374
|
||||
11377
|
|
@ -1,601 +0,0 @@
|
|||
26,38,2,15,36,8,12,46,88,72,32,35,64,19,5,66,20,52,74,3,59,94,45,56,0,6,67,24,97,50,92,93,84,65,71,90,96,21,87,75,58,82,14,53,95,27,49,69,16,89,37,13,1,81,60,79,51,18,48,33,42,63,39,34,62,55,47,54,23,83,77,9,70,68,85,86,91,41,4,61,78,31,22,76,40,17,30,98,44,25,80,73,11,28,7,99,29,57,43,10
|
||||
|
||||
57 12 60 96 93
|
||||
73 87 63 70 91
|
||||
74 32 43 67 46
|
||||
59 34 5 35 82
|
||||
53 40 55 29 1
|
||||
|
||||
48 71 59 45 63
|
||||
13 42 23 95 39
|
||||
84 82 10 29 4
|
||||
16 91 32 92 62
|
||||
99 33 20 21 3
|
||||
|
||||
51 20 32 30 90
|
||||
86 88 89 1 73
|
||||
5 64 78 81 22
|
||||
95 50 7 27 17
|
||||
39 82 46 35 92
|
||||
|
||||
2 65 21 77 97
|
||||
50 46 38 99 82
|
||||
22 1 24 63 70
|
||||
8 32 80 98 35
|
||||
57 67 25 81 18
|
||||
|
||||
64 7 26 44 14
|
||||
42 71 19 22 0
|
||||
4 36 51 25 6
|
||||
69 59 90 15 88
|
||||
85 65 32 76 70
|
||||
|
||||
8 69 75 42 44
|
||||
64 25 72 71 34
|
||||
2 94 81 14 38
|
||||
97 89 59 23 88
|
||||
57 70 13 1 51
|
||||
|
||||
93 94 26 11 35
|
||||
63 57 84 10 92
|
||||
12 29 78 65 64
|
||||
54 75 61 50 81
|
||||
13 90 2 66 99
|
||||
|
||||
10 21 39 24 56
|
||||
90 49 25 80 59
|
||||
41 72 47 74 79
|
||||
9 89 42 92 31
|
||||
20 1 32 58 83
|
||||
|
||||
81 11 58 2 69
|
||||
79 23 60 8 63
|
||||
94 9 0 45 34
|
||||
36 31 61 71 74
|
||||
51 48 59 99 70
|
||||
|
||||
66 47 88 16 18
|
||||
35 75 54 26 77
|
||||
23 55 33 3 19
|
||||
82 71 57 80 45
|
||||
22 8 40 76 20
|
||||
|
||||
8 5 95 86 76
|
||||
49 21 82 78 77
|
||||
12 38 61 85 4
|
||||
14 54 42 40 39
|
||||
69 66 1 0 7
|
||||
|
||||
85 66 96 45 64
|
||||
25 55 36 76 37
|
||||
82 61 29 47 54
|
||||
73 94 3 59 24
|
||||
71 62 31 98 79
|
||||
|
||||
84 10 60 61 97
|
||||
75 90 95 6 8
|
||||
93 89 65 70 80
|
||||
35 15 46 55 77
|
||||
52 3 74 39 36
|
||||
|
||||
80 24 59 71 52
|
||||
17 43 45 8 6
|
||||
58 22 32 46 98
|
||||
48 3 56 31 77
|
||||
97 28 55 0 76
|
||||
|
||||
51 98 12 49 19
|
||||
28 94 9 97 85
|
||||
5 78 47 93 24
|
||||
67 0 37 81 76
|
||||
77 48 15 69 50
|
||||
|
||||
34 45 5 80 14
|
||||
82 42 63 2 86
|
||||
3 95 54 74 69
|
||||
46 27 49 92 66
|
||||
0 85 98 83 17
|
||||
|
||||
41 99 93 62 96
|
||||
90 30 10 5 94
|
||||
98 32 83 78 25
|
||||
76 27 29 19 35
|
||||
58 91 34 31 3
|
||||
|
||||
31 1 24 96 36
|
||||
58 12 59 57 92
|
||||
84 5 55 49 41
|
||||
54 72 70 95 88
|
||||
66 50 22 35 15
|
||||
|
||||
35 57 69 13 93
|
||||
34 62 28 26 36
|
||||
6 64 47 74 45
|
||||
0 32 19 33 44
|
||||
65 25 90 91 1
|
||||
|
||||
57 96 70 15 89
|
||||
7 65 29 12 34
|
||||
40 25 36 81 86
|
||||
58 39 27 79 59
|
||||
19 91 47 6 11
|
||||
|
||||
60 74 67 87 68
|
||||
80 53 42 91 89
|
||||
11 19 8 78 31
|
||||
4 6 30 10 90
|
||||
64 41 27 59 12
|
||||
|
||||
45 0 86 81 34
|
||||
8 29 53 12 32
|
||||
89 74 64 26 96
|
||||
60 13 87 35 73
|
||||
52 69 23 46 40
|
||||
|
||||
43 35 1 59 40
|
||||
63 74 7 53 94
|
||||
39 42 8 84 27
|
||||
66 65 46 82 80
|
||||
61 76 13 31 45
|
||||
|
||||
38 4 51 76 5
|
||||
36 57 3 86 84
|
||||
83 37 60 67 52
|
||||
0 70 7 19 72
|
||||
62 99 9 75 58
|
||||
|
||||
95 47 78 27 14
|
||||
50 82 17 15 22
|
||||
1 76 64 73 71
|
||||
24 26 42 79 55
|
||||
36 40 43 81 59
|
||||
|
||||
13 7 60 49 87
|
||||
30 31 99 19 82
|
||||
91 88 53 96 97
|
||||
37 11 47 32 81
|
||||
86 94 45 71 38
|
||||
|
||||
64 42 19 6 69
|
||||
33 2 61 98 55
|
||||
20 48 5 82 56
|
||||
78 11 65 59 74
|
||||
85 72 1 54 29
|
||||
|
||||
76 56 84 34 83
|
||||
16 26 33 50 3
|
||||
85 20 87 31 51
|
||||
62 7 28 96 8
|
||||
81 57 89 44 58
|
||||
|
||||
92 49 58 8 45
|
||||
47 89 48 91 71
|
||||
53 67 37 59 88
|
||||
24 69 96 61 16
|
||||
2 6 68 95 60
|
||||
|
||||
99 60 39 96 0
|
||||
62 14 77 70 47
|
||||
72 98 66 42 58
|
||||
85 19 12 23 44
|
||||
68 28 51 94 82
|
||||
|
||||
59 32 45 99 92
|
||||
96 36 30 87 9
|
||||
61 54 71 94 22
|
||||
76 4 62 20 2
|
||||
40 18 43 70 44
|
||||
|
||||
22 54 77 12 3
|
||||
5 11 41 19 58
|
||||
49 51 75 24 63
|
||||
42 20 43 92 69
|
||||
62 36 15 25 80
|
||||
|
||||
93 40 48 21 10
|
||||
0 83 86 31 65
|
||||
52 7 17 67 72
|
||||
95 28 63 99 47
|
||||
51 22 85 55 44
|
||||
|
||||
43 26 86 80 94
|
||||
93 66 84 90 61
|
||||
91 58 71 73 89
|
||||
9 72 81 48 54
|
||||
11 60 36 25 70
|
||||
|
||||
33 42 73 20 69
|
||||
15 12 27 72 14
|
||||
93 30 89 86 22
|
||||
77 25 80 85 74
|
||||
66 78 0 49 82
|
||||
|
||||
37 84 46 86 39
|
||||
55 31 96 17 43
|
||||
12 33 45 97 9
|
||||
44 57 25 77 78
|
||||
5 73 81 35 58
|
||||
|
||||
19 41 87 94 59
|
||||
97 84 78 52 77
|
||||
70 15 91 53 1
|
||||
71 47 82 35 99
|
||||
25 55 58 39 29
|
||||
|
||||
29 74 31 73 72
|
||||
23 10 83 63 25
|
||||
18 26 79 35 65
|
||||
59 44 98 45 20
|
||||
67 7 87 28 11
|
||||
|
||||
83 89 92 55 72
|
||||
32 6 78 93 49
|
||||
66 77 5 60 61
|
||||
85 57 29 97 65
|
||||
86 84 48 20 75
|
||||
|
||||
85 82 83 66 86
|
||||
64 61 77 38 84
|
||||
1 68 4 18 72
|
||||
56 97 37 98 74
|
||||
44 14 78 52 93
|
||||
|
||||
30 73 72 24 51
|
||||
78 3 97 39 5
|
||||
90 42 58 96 17
|
||||
33 95 44 27 1
|
||||
80 16 84 54 99
|
||||
|
||||
92 88 79 14 10
|
||||
24 52 80 46 51
|
||||
11 31 35 53 25
|
||||
44 54 63 33 93
|
||||
87 38 15 64 4
|
||||
|
||||
14 25 61 40 95
|
||||
34 17 97 38 26
|
||||
64 90 45 91 65
|
||||
8 50 23 11 74
|
||||
32 33 22 88 28
|
||||
|
||||
8 32 94 72 74
|
||||
27 29 22 2 76
|
||||
58 54 80 5 35
|
||||
36 24 83 59 25
|
||||
21 31 48 39 4
|
||||
|
||||
56 13 22 53 72
|
||||
61 60 81 87 86
|
||||
7 74 98 28 11
|
||||
67 38 91 23 0
|
||||
42 84 24 3 47
|
||||
|
||||
29 98 43 45 30
|
||||
86 50 15 60 11
|
||||
18 34 8 67 24
|
||||
36 97 69 27 79
|
||||
35 87 52 55 61
|
||||
|
||||
40 50 30 75 72
|
||||
1 62 85 21 11
|
||||
80 10 91 7 2
|
||||
27 31 73 25 29
|
||||
63 65 55 87 23
|
||||
|
||||
12 68 47 77 76
|
||||
98 30 6 51 80
|
||||
22 85 88 99 24
|
||||
35 90 82 18 37
|
||||
17 27 34 54 43
|
||||
|
||||
85 46 35 16 45
|
||||
4 6 96 9 61
|
||||
44 90 64 29 50
|
||||
76 38 69 80 28
|
||||
27 23 51 8 7
|
||||
|
||||
72 8 62 61 83
|
||||
0 30 92 29 7
|
||||
86 28 54 52 5
|
||||
32 97 82 68 31
|
||||
76 69 22 12 13
|
||||
|
||||
66 67 1 36 94
|
||||
80 99 49 47 38
|
||||
76 95 30 13 19
|
||||
83 21 45 44 43
|
||||
29 91 14 20 98
|
||||
|
||||
8 80 3 82 99
|
||||
62 41 47 6 27
|
||||
12 72 76 81 36
|
||||
30 7 67 90 5
|
||||
85 31 83 49 19
|
||||
|
||||
25 91 86 47 27
|
||||
69 74 20 17 97
|
||||
59 45 87 28 75
|
||||
49 94 63 33 9
|
||||
8 66 2 30 32
|
||||
|
||||
69 58 41 84 5
|
||||
27 2 22 65 88
|
||||
63 96 90 17 85
|
||||
26 52 86 20 8
|
||||
3 9 59 50 57
|
||||
|
||||
80 85 90 5 56
|
||||
66 57 76 65 62
|
||||
81 74 15 38 32
|
||||
0 75 61 16 79
|
||||
96 50 8 86 1
|
||||
|
||||
52 21 98 54 94
|
||||
73 90 87 58 50
|
||||
38 39 30 69 82
|
||||
55 12 81 48 29
|
||||
93 23 91 47 28
|
||||
|
||||
92 14 3 1 19
|
||||
18 27 91 62 86
|
||||
61 80 49 53 97
|
||||
77 98 52 0 8
|
||||
17 54 85 59 51
|
||||
|
||||
49 45 38 70 33
|
||||
96 18 63 5 99
|
||||
65 58 29 91 19
|
||||
78 7 98 39 17
|
||||
31 15 13 35 75
|
||||
|
||||
55 50 58 96 94
|
||||
67 72 4 40 90
|
||||
59 31 15 78 81
|
||||
1 80 56 34 20
|
||||
27 52 88 75 53
|
||||
|
||||
0 5 91 65 72
|
||||
53 42 4 50 25
|
||||
13 52 81 79 92
|
||||
46 89 55 58 95
|
||||
19 77 30 36 18
|
||||
|
||||
38 97 86 69 44
|
||||
70 52 14 19 29
|
||||
9 36 96 24 80
|
||||
84 22 32 72 48
|
||||
28 3 46 42 87
|
||||
|
||||
94 93 31 33 38
|
||||
21 30 34 69 35
|
||||
1 10 55 79 57
|
||||
54 28 44 78 73
|
||||
8 20 45 41 23
|
||||
|
||||
32 13 49 80 68
|
||||
41 95 84 74 57
|
||||
15 61 5 77 67
|
||||
53 54 29 51 75
|
||||
24 66 36 88 90
|
||||
|
||||
74 49 19 2 66
|
||||
94 45 30 84 37
|
||||
7 24 22 87 60
|
||||
13 40 57 9 1
|
||||
56 42 92 67 27
|
||||
|
||||
29 7 97 22 36
|
||||
80 77 92 3 67
|
||||
48 54 73 51 41
|
||||
28 8 55 24 4
|
||||
13 11 66 5 86
|
||||
|
||||
76 16 8 71 92
|
||||
23 61 53 27 43
|
||||
25 6 17 32 64
|
||||
40 69 21 84 93
|
||||
89 30 55 90 41
|
||||
|
||||
86 22 81 13 33
|
||||
35 87 82 77 71
|
||||
96 65 37 62 51
|
||||
16 72 36 93 23
|
||||
84 44 26 66 27
|
||||
|
||||
4 73 52 35 43
|
||||
39 9 96 34 70
|
||||
19 67 38 10 54
|
||||
21 7 36 13 90
|
||||
84 28 59 57 75
|
||||
|
||||
55 7 32 68 97
|
||||
10 56 46 28 66
|
||||
74 81 18 73 26
|
||||
44 76 13 35 61
|
||||
90 36 45 64 58
|
||||
|
||||
96 62 97 87 95
|
||||
45 78 38 84 41
|
||||
91 19 88 25 22
|
||||
12 27 31 92 5
|
||||
15 83 7 53 71
|
||||
|
||||
31 17 96 6 47
|
||||
3 90 27 89 75
|
||||
53 39 62 82 13
|
||||
52 34 23 83 87
|
||||
19 67 50 98 84
|
||||
|
||||
96 3 70 17 42
|
||||
50 74 65 53 31
|
||||
52 80 18 26 77
|
||||
29 57 95 25 81
|
||||
88 92 55 13 28
|
||||
|
||||
63 34 56 1 4
|
||||
40 97 10 5 50
|
||||
96 55 15 68 37
|
||||
43 33 89 72 3
|
||||
11 88 44 86 2
|
||||
|
||||
65 44 24 34 41
|
||||
1 68 67 6 26
|
||||
27 88 73 25 9
|
||||
55 56 16 48 29
|
||||
33 18 77 3 94
|
||||
|
||||
91 75 35 33 56
|
||||
96 19 69 81 53
|
||||
25 14 32 74 22
|
||||
24 6 89 42 90
|
||||
9 2 77 67 20
|
||||
|
||||
19 97 36 78 71
|
||||
16 26 99 23 92
|
||||
10 68 74 90 88
|
||||
30 60 96 11 34
|
||||
8 76 35 53 22
|
||||
|
||||
84 15 76 31 63
|
||||
1 34 96 70 35
|
||||
66 57 71 26 61
|
||||
83 41 74 85 60
|
||||
16 28 30 23 49
|
||||
|
||||
72 88 56 92 86
|
||||
12 44 71 47 30
|
||||
39 53 4 46 45
|
||||
38 5 9 35 25
|
||||
8 61 13 50 82
|
||||
|
||||
62 92 49 21 95
|
||||
70 47 73 74 56
|
||||
17 89 0 39 60
|
||||
42 99 13 63 67
|
||||
43 16 11 20 84
|
||||
|
||||
13 30 59 84 12
|
||||
52 88 79 62 29
|
||||
99 39 95 55 70
|
||||
80 46 31 89 69
|
||||
74 71 65 3 38
|
||||
|
||||
47 86 21 24 22
|
||||
0 62 69 38 59
|
||||
27 10 41 81 92
|
||||
14 51 35 13 17
|
||||
30 15 7 71 70
|
||||
|
||||
25 26 29 66 32
|
||||
68 46 77 45 86
|
||||
14 15 90 40 22
|
||||
6 36 17 76 1
|
||||
80 55 83 98 79
|
||||
|
||||
98 76 58 27 39
|
||||
45 90 56 46 69
|
||||
10 41 54 82 25
|
||||
94 86 89 33 79
|
||||
16 30 87 24 83
|
||||
|
||||
66 28 93 91 68
|
||||
71 51 22 10 42
|
||||
29 20 77 17 8
|
||||
55 39 89 72 12
|
||||
98 78 65 48 41
|
||||
|
||||
49 25 80 64 99
|
||||
90 9 40 76 63
|
||||
60 93 46 4 27
|
||||
17 0 42 33 28
|
||||
59 26 18 69 75
|
||||
|
||||
35 0 76 58 31
|
||||
87 17 42 13 33
|
||||
70 67 61 52 12
|
||||
59 85 64 80 1
|
||||
4 73 99 55 48
|
||||
|
||||
40 73 94 80 90
|
||||
9 93 17 51 62
|
||||
96 0 57 82 47
|
||||
86 27 64 95 84
|
||||
16 99 37 41 44
|
||||
|
||||
8 96 31 26 50
|
||||
20 69 75 82 89
|
||||
94 42 38 78 35
|
||||
83 13 45 62 43
|
||||
97 14 34 17 47
|
||||
|
||||
35 88 38 7 97
|
||||
8 79 51 74 26
|
||||
60 22 53 5 33
|
||||
63 23 69 0 83
|
||||
21 44 91 95 18
|
||||
|
||||
64 77 4 0 15
|
||||
80 66 9 16 5
|
||||
75 8 18 40 91
|
||||
72 1 49 60 97
|
||||
14 24 34 65 92
|
||||
|
||||
84 75 31 56 55
|
||||
17 92 48 45 89
|
||||
88 52 10 90 47
|
||||
91 97 6 39 79
|
||||
99 65 11 42 93
|
||||
|
||||
7 82 10 88 49
|
||||
11 66 54 3 53
|
||||
4 73 71 42 92
|
||||
22 75 84 16 48
|
||||
5 94 79 96 45
|
||||
|
||||
20 87 16 25 9
|
||||
15 70 19 72 56
|
||||
71 37 69 2 62
|
||||
76 97 41 8 92
|
||||
40 65 86 0 32
|
||||
|
||||
81 48 14 75 4
|
||||
70 30 6 74 62
|
||||
15 28 55 22 63
|
||||
36 32 35 86 71
|
||||
29 47 59 18 78
|
||||
|
||||
10 35 27 14 64
|
||||
43 19 86 71 36
|
||||
32 79 9 51 91
|
||||
17 67 26 41 56
|
||||
15 1 95 13 65
|
||||
|
||||
74 79 22 30 46
|
||||
80 55 57 14 37
|
||||
59 88 40 83 56
|
||||
63 10 97 64 7
|
||||
77 61 53 91 20
|
||||
|
||||
53 81 13 72 67
|
||||
79 10 71 11 8
|
||||
0 99 60 20 4
|
||||
7 45 89 66 98
|
||||
50 36 80 57 5
|
||||
|
||||
5 7 35 4 29
|
||||
28 65 31 86 33
|
||||
66 98 75 13 92
|
||||
38 67 80 46 11
|
||||
9 15 57 71 32
|
||||
|
||||
21 33 22 77 5
|
||||
0 6 59 37 69
|
||||
50 45 32 60 96
|
||||
9 39 28 56 57
|
||||
34 46 43 52 25
|
||||
|
||||
67 11 21 53 60
|
||||
52 58 54 94 47
|
||||
84 46 72 81 16
|
||||
31 51 23 36 97
|
||||
80 43 75 99 79
|
|
@ -1,2 +0,0 @@
|
|||
5442
|
||||
19571
|
|
@ -1,500 +0,0 @@
|
|||
62,963 -> 844,181
|
||||
58,85 -> 917,944
|
||||
137,76 -> 137,347
|
||||
453,125 -> 347,19
|
||||
178,65 -> 977,864
|
||||
447,360 -> 62,745
|
||||
723,326 -> 156,893
|
||||
47,497 -> 107,437
|
||||
387,491 -> 340,491
|
||||
58,477 -> 283,252
|
||||
86,351 -> 562,827
|
||||
215,172 -> 539,172
|
||||
496,801 -> 496,63
|
||||
546,412 -> 232,98
|
||||
621,807 -> 481,807
|
||||
471,20 -> 618,20
|
||||
175,283 -> 175,467
|
||||
19,283 -> 19,290
|
||||
159,137 -> 159,11
|
||||
593,181 -> 543,181
|
||||
167,976 -> 929,976
|
||||
730,782 -> 959,782
|
||||
713,285 -> 713,880
|
||||
583,144 -> 583,296
|
||||
39,61 -> 961,983
|
||||
778,81 -> 604,81
|
||||
70,560 -> 70,889
|
||||
85,129 -> 666,710
|
||||
689,688 -> 632,688
|
||||
76,52 -> 903,879
|
||||
510,543 -> 22,55
|
||||
510,935 -> 470,935
|
||||
780,357 -> 780,602
|
||||
440,349 -> 710,79
|
||||
934,801 -> 412,801
|
||||
979,25 -> 35,969
|
||||
379,527 -> 379,76
|
||||
243,524 -> 243,664
|
||||
534,945 -> 11,422
|
||||
198,367 -> 224,367
|
||||
871,451 -> 456,451
|
||||
226,231 -> 939,231
|
||||
686,354 -> 740,300
|
||||
543,68 -> 340,68
|
||||
506,160 -> 319,347
|
||||
177,25 -> 177,603
|
||||
337,450 -> 724,450
|
||||
421,519 -> 676,519
|
||||
858,976 -> 179,297
|
||||
236,222 -> 236,250
|
||||
254,242 -> 254,626
|
||||
859,243 -> 23,243
|
||||
89,982 -> 979,92
|
||||
58,758 -> 101,801
|
||||
930,483 -> 587,826
|
||||
667,717 -> 667,762
|
||||
512,816 -> 845,816
|
||||
17,501 -> 17,760
|
||||
345,61 -> 847,61
|
||||
531,840 -> 618,840
|
||||
67,748 -> 262,748
|
||||
548,461 -> 163,846
|
||||
934,142 -> 169,907
|
||||
119,931 -> 580,470
|
||||
769,916 -> 457,604
|
||||
587,458 -> 93,458
|
||||
109,850 -> 768,191
|
||||
225,129 -> 160,64
|
||||
544,163 -> 544,476
|
||||
304,594 -> 61,351
|
||||
510,396 -> 510,741
|
||||
772,210 -> 772,889
|
||||
867,415 -> 721,269
|
||||
466,266 -> 466,44
|
||||
305,609 -> 305,237
|
||||
563,962 -> 451,962
|
||||
566,402 -> 28,940
|
||||
889,717 -> 891,717
|
||||
754,545 -> 313,545
|
||||
930,976 -> 209,255
|
||||
70,911 -> 692,289
|
||||
737,37 -> 958,37
|
||||
652,566 -> 720,634
|
||||
776,551 -> 370,957
|
||||
484,476 -> 820,476
|
||||
119,420 -> 639,420
|
||||
394,964 -> 394,221
|
||||
340,767 -> 964,143
|
||||
715,289 -> 481,55
|
||||
236,389 -> 826,389
|
||||
747,642 -> 33,642
|
||||
583,351 -> 244,690
|
||||
609,17 -> 609,680
|
||||
460,365 -> 668,365
|
||||
519,180 -> 929,590
|
||||
206,45 -> 782,45
|
||||
507,185 -> 386,306
|
||||
16,12 -> 982,978
|
||||
31,348 -> 320,348
|
||||
54,975 -> 947,82
|
||||
844,714 -> 870,714
|
||||
677,965 -> 677,699
|
||||
387,699 -> 387,26
|
||||
329,479 -> 189,479
|
||||
970,708 -> 538,708
|
||||
565,434 -> 565,623
|
||||
748,737 -> 748,497
|
||||
255,984 -> 255,600
|
||||
146,59 -> 932,845
|
||||
191,929 -> 423,929
|
||||
316,409 -> 802,409
|
||||
208,560 -> 559,209
|
||||
885,237 -> 135,987
|
||||
477,486 -> 260,486
|
||||
845,59 -> 845,811
|
||||
225,369 -> 162,369
|
||||
858,678 -> 858,362
|
||||
162,972 -> 27,972
|
||||
828,26 -> 283,571
|
||||
670,48 -> 114,604
|
||||
732,487 -> 620,487
|
||||
570,575 -> 14,19
|
||||
113,203 -> 162,154
|
||||
374,702 -> 374,452
|
||||
850,575 -> 535,575
|
||||
841,133 -> 841,474
|
||||
976,960 -> 642,960
|
||||
177,428 -> 177,246
|
||||
969,289 -> 589,289
|
||||
787,842 -> 731,786
|
||||
743,709 -> 336,709
|
||||
15,914 -> 299,630
|
||||
863,952 -> 17,952
|
||||
586,889 -> 586,512
|
||||
442,128 -> 436,128
|
||||
633,367 -> 79,921
|
||||
21,990 -> 257,990
|
||||
829,297 -> 829,103
|
||||
975,633 -> 879,633
|
||||
946,887 -> 72,13
|
||||
531,720 -> 123,312
|
||||
84,954 -> 815,223
|
||||
989,982 -> 257,982
|
||||
669,417 -> 928,158
|
||||
128,935 -> 87,976
|
||||
692,850 -> 191,850
|
||||
686,856 -> 686,259
|
||||
135,396 -> 473,58
|
||||
837,206 -> 629,206
|
||||
751,227 -> 751,900
|
||||
190,617 -> 190,502
|
||||
850,265 -> 254,265
|
||||
229,587 -> 325,491
|
||||
980,747 -> 465,232
|
||||
54,375 -> 439,375
|
||||
737,844 -> 711,844
|
||||
533,219 -> 123,629
|
||||
232,805 -> 232,798
|
||||
911,441 -> 911,160
|
||||
80,294 -> 80,527
|
||||
880,533 -> 590,533
|
||||
674,84 -> 674,670
|
||||
956,440 -> 554,842
|
||||
24,939 -> 890,73
|
||||
516,183 -> 145,554
|
||||
71,584 -> 71,766
|
||||
629,173 -> 643,187
|
||||
34,360 -> 639,965
|
||||
983,871 -> 983,682
|
||||
986,590 -> 986,327
|
||||
769,986 -> 130,986
|
||||
392,192 -> 70,192
|
||||
577,379 -> 635,379
|
||||
243,664 -> 162,664
|
||||
273,987 -> 273,192
|
||||
251,548 -> 558,855
|
||||
989,736 -> 989,611
|
||||
400,697 -> 134,431
|
||||
646,923 -> 646,841
|
||||
768,782 -> 386,782
|
||||
93,973 -> 939,127
|
||||
489,91 -> 489,551
|
||||
313,683 -> 248,748
|
||||
986,61 -> 201,846
|
||||
322,413 -> 737,413
|
||||
567,716 -> 567,614
|
||||
198,624 -> 439,624
|
||||
402,198 -> 147,453
|
||||
897,352 -> 897,298
|
||||
773,379 -> 773,19
|
||||
373,256 -> 931,814
|
||||
690,796 -> 543,796
|
||||
884,368 -> 464,368
|
||||
136,864 -> 622,378
|
||||
458,569 -> 458,254
|
||||
491,462 -> 491,412
|
||||
558,340 -> 73,340
|
||||
980,52 -> 980,605
|
||||
126,609 -> 390,345
|
||||
437,659 -> 17,659
|
||||
53,928 -> 982,928
|
||||
389,591 -> 389,832
|
||||
464,46 -> 464,754
|
||||
646,680 -> 646,988
|
||||
919,159 -> 109,969
|
||||
334,75 -> 219,75
|
||||
976,639 -> 976,685
|
||||
264,773 -> 128,773
|
||||
787,771 -> 699,771
|
||||
415,124 -> 549,124
|
||||
468,71 -> 468,701
|
||||
815,121 -> 797,121
|
||||
619,95 -> 610,104
|
||||
886,294 -> 120,294
|
||||
148,136 -> 148,314
|
||||
816,971 -> 454,971
|
||||
888,733 -> 431,733
|
||||
59,836 -> 840,55
|
||||
52,965 -> 962,55
|
||||
989,982 -> 19,12
|
||||
697,818 -> 185,306
|
||||
883,638 -> 481,638
|
||||
429,285 -> 170,26
|
||||
516,507 -> 516,301
|
||||
767,102 -> 61,808
|
||||
764,793 -> 209,238
|
||||
568,411 -> 261,718
|
||||
706,622 -> 685,622
|
||||
226,110 -> 790,674
|
||||
544,429 -> 544,334
|
||||
794,588 -> 794,792
|
||||
804,738 -> 782,738
|
||||
370,552 -> 370,189
|
||||
960,275 -> 644,275
|
||||
133,896 -> 686,896
|
||||
12,986 -> 987,11
|
||||
978,973 -> 69,64
|
||||
92,465 -> 62,465
|
||||
733,57 -> 18,57
|
||||
110,845 -> 110,272
|
||||
123,935 -> 123,499
|
||||
37,960 -> 986,11
|
||||
332,209 -> 344,221
|
||||
237,279 -> 349,279
|
||||
875,635 -> 875,420
|
||||
552,174 -> 552,635
|
||||
10,93 -> 853,936
|
||||
909,82 -> 909,926
|
||||
511,743 -> 511,830
|
||||
223,974 -> 223,124
|
||||
829,543 -> 11,543
|
||||
307,671 -> 206,570
|
||||
126,72 -> 956,72
|
||||
528,903 -> 528,223
|
||||
644,524 -> 952,216
|
||||
734,324 -> 734,105
|
||||
225,558 -> 225,159
|
||||
667,122 -> 667,64
|
||||
582,93 -> 582,509
|
||||
817,932 -> 727,932
|
||||
898,18 -> 79,837
|
||||
12,987 -> 986,13
|
||||
426,79 -> 722,79
|
||||
496,884 -> 906,884
|
||||
953,183 -> 953,508
|
||||
360,881 -> 975,881
|
||||
765,862 -> 579,862
|
||||
14,55 -> 14,560
|
||||
454,333 -> 290,333
|
||||
19,479 -> 91,551
|
||||
696,41 -> 56,41
|
||||
329,203 -> 812,203
|
||||
498,559 -> 498,636
|
||||
822,852 -> 614,852
|
||||
410,370 -> 410,624
|
||||
829,415 -> 805,415
|
||||
775,980 -> 204,980
|
||||
705,780 -> 116,191
|
||||
49,30 -> 988,969
|
||||
324,199 -> 554,199
|
||||
727,572 -> 157,572
|
||||
212,693 -> 93,693
|
||||
886,105 -> 152,105
|
||||
239,834 -> 958,115
|
||||
623,920 -> 623,523
|
||||
389,225 -> 106,508
|
||||
443,426 -> 443,108
|
||||
129,770 -> 858,41
|
||||
906,559 -> 392,559
|
||||
44,793 -> 774,793
|
||||
693,275 -> 693,738
|
||||
623,434 -> 184,873
|
||||
774,623 -> 774,895
|
||||
140,187 -> 140,238
|
||||
247,503 -> 45,301
|
||||
575,365 -> 950,365
|
||||
101,120 -> 646,120
|
||||
42,682 -> 649,75
|
||||
749,767 -> 516,534
|
||||
551,53 -> 73,531
|
||||
15,26 -> 885,896
|
||||
749,15 -> 235,529
|
||||
548,169 -> 784,405
|
||||
458,564 -> 962,564
|
||||
663,873 -> 678,873
|
||||
349,773 -> 349,927
|
||||
777,180 -> 637,320
|
||||
238,306 -> 844,912
|
||||
927,818 -> 652,543
|
||||
404,673 -> 952,125
|
||||
750,297 -> 18,297
|
||||
926,958 -> 926,669
|
||||
767,843 -> 767,833
|
||||
151,136 -> 234,219
|
||||
927,789 -> 468,330
|
||||
593,361 -> 593,447
|
||||
48,14 -> 954,920
|
||||
282,972 -> 790,972
|
||||
537,446 -> 202,446
|
||||
847,125 -> 357,615
|
||||
667,609 -> 299,609
|
||||
820,987 -> 359,987
|
||||
342,889 -> 595,889
|
||||
692,414 -> 239,414
|
||||
916,935 -> 70,89
|
||||
289,884 -> 289,790
|
||||
264,562 -> 373,562
|
||||
850,24 -> 126,748
|
||||
877,159 -> 213,823
|
||||
702,607 -> 702,454
|
||||
432,883 -> 432,260
|
||||
530,387 -> 229,387
|
||||
783,39 -> 783,933
|
||||
757,775 -> 757,81
|
||||
416,376 -> 474,376
|
||||
220,462 -> 220,824
|
||||
438,317 -> 421,317
|
||||
403,312 -> 866,312
|
||||
902,923 -> 204,923
|
||||
345,33 -> 819,33
|
||||
376,521 -> 549,521
|
||||
172,320 -> 129,277
|
||||
25,975 -> 976,24
|
||||
730,108 -> 465,373
|
||||
607,468 -> 737,598
|
||||
376,55 -> 672,55
|
||||
807,113 -> 974,113
|
||||
345,804 -> 695,454
|
||||
687,921 -> 650,884
|
||||
262,743 -> 262,753
|
||||
889,734 -> 499,344
|
||||
424,727 -> 909,242
|
||||
100,957 -> 100,832
|
||||
558,958 -> 376,958
|
||||
422,473 -> 539,356
|
||||
424,463 -> 158,463
|
||||
329,543 -> 816,543
|
||||
300,74 -> 362,136
|
||||
620,691 -> 620,312
|
||||
215,727 -> 360,582
|
||||
692,116 -> 618,116
|
||||
945,722 -> 945,560
|
||||
851,83 -> 450,484
|
||||
692,424 -> 254,862
|
||||
160,214 -> 160,405
|
||||
937,101 -> 854,184
|
||||
989,14 -> 18,985
|
||||
256,275 -> 828,847
|
||||
797,748 -> 509,748
|
||||
521,148 -> 422,148
|
||||
85,549 -> 85,807
|
||||
689,688 -> 443,442
|
||||
750,664 -> 648,562
|
||||
51,616 -> 51,54
|
||||
925,272 -> 925,696
|
||||
284,560 -> 369,560
|
||||
509,685 -> 509,559
|
||||
985,157 -> 273,869
|
||||
570,765 -> 614,721
|
||||
62,981 -> 985,58
|
||||
289,496 -> 289,104
|
||||
752,232 -> 692,292
|
||||
82,948 -> 683,948
|
||||
15,20 -> 984,989
|
||||
252,950 -> 252,132
|
||||
930,659 -> 614,659
|
||||
552,449 -> 798,695
|
||||
850,894 -> 342,386
|
||||
412,465 -> 412,383
|
||||
249,616 -> 351,718
|
||||
759,289 -> 613,289
|
||||
673,347 -> 673,842
|
||||
749,493 -> 449,493
|
||||
378,468 -> 378,674
|
||||
914,924 -> 890,900
|
||||
514,56 -> 606,56
|
||||
855,233 -> 979,233
|
||||
170,756 -> 170,961
|
||||
450,601 -> 450,87
|
||||
868,192 -> 125,935
|
||||
702,137 -> 231,608
|
||||
109,36 -> 632,36
|
||||
511,472 -> 511,945
|
||||
208,884 -> 923,169
|
||||
831,66 -> 146,66
|
||||
435,133 -> 884,133
|
||||
900,418 -> 916,418
|
||||
957,104 -> 127,104
|
||||
608,892 -> 608,40
|
||||
554,782 -> 55,782
|
||||
305,260 -> 305,712
|
||||
942,143 -> 226,859
|
||||
823,778 -> 317,778
|
||||
228,415 -> 228,445
|
||||
313,505 -> 669,505
|
||||
43,539 -> 43,187
|
||||
14,84 -> 743,813
|
||||
687,101 -> 277,101
|
||||
549,977 -> 549,392
|
||||
21,637 -> 214,637
|
||||
950,961 -> 104,115
|
||||
778,831 -> 958,831
|
||||
214,765 -> 579,765
|
||||
586,42 -> 89,42
|
||||
505,950 -> 505,115
|
||||
144,734 -> 144,813
|
||||
11,349 -> 11,681
|
||||
49,336 -> 99,386
|
||||
560,187 -> 560,551
|
||||
678,602 -> 761,519
|
||||
131,515 -> 411,795
|
||||
957,835 -> 957,106
|
||||
948,852 -> 948,990
|
||||
541,946 -> 541,405
|
||||
355,147 -> 724,516
|
||||
644,476 -> 625,476
|
||||
789,818 -> 207,236
|
||||
259,57 -> 431,57
|
||||
441,375 -> 441,34
|
||||
774,121 -> 882,13
|
||||
655,397 -> 188,864
|
||||
467,432 -> 235,200
|
||||
268,121 -> 268,842
|
||||
975,14 -> 11,978
|
||||
124,904 -> 935,93
|
||||
401,582 -> 420,582
|
||||
170,700 -> 523,347
|
||||
20,681 -> 20,174
|
||||
420,939 -> 173,692
|
||||
61,933 -> 956,38
|
||||
686,458 -> 686,939
|
||||
780,561 -> 305,86
|
||||
792,644 -> 792,780
|
||||
632,550 -> 938,550
|
||||
441,252 -> 841,252
|
||||
789,59 -> 789,418
|
||||
981,11 -> 278,714
|
||||
264,41 -> 264,186
|
||||
870,833 -> 605,568
|
||||
160,905 -> 160,783
|
||||
385,191 -> 385,403
|
||||
774,791 -> 69,86
|
||||
409,967 -> 409,173
|
||||
868,41 -> 868,235
|
||||
536,497 -> 949,497
|
||||
757,119 -> 156,720
|
||||
563,706 -> 883,706
|
||||
124,482 -> 14,482
|
||||
353,655 -> 904,104
|
||||
194,868 -> 194,649
|
||||
810,736 -> 748,736
|
||||
815,578 -> 50,578
|
||||
531,131 -> 241,131
|
||||
18,972 -> 977,13
|
||||
761,747 -> 73,59
|
||||
650,701 -> 930,701
|
||||
470,237 -> 470,740
|
||||
333,803 -> 954,182
|
||||
644,667 -> 235,667
|
||||
943,766 -> 299,766
|
||||
985,876 -> 985,503
|
||||
170,924 -> 467,924
|
||||
249,19 -> 981,751
|
||||
462,666 -> 462,651
|
||||
404,228 -> 877,228
|
||||
174,440 -> 174,847
|
||||
910,596 -> 672,596
|
||||
430,663 -> 734,663
|
||||
711,294 -> 69,294
|
||||
193,302 -> 257,302
|
||||
959,20 -> 13,966
|
||||
171,561 -> 171,953
|
||||
704,986 -> 29,311
|
||||
285,886 -> 285,260
|
||||
945,872 -> 531,458
|
||||
265,748 -> 478,748
|
||||
26,537 -> 26,851
|
||||
205,210 -> 917,922
|
||||
590,488 -> 241,139
|
||||
536,179 -> 247,179
|
|
@ -1,2 +0,0 @@
|
|||
391888
|
||||
1754597645339
|
|
@ -1 +0,0 @@
|
|||
5,1,1,4,1,1,4,1,1,1,1,1,1,1,1,1,1,1,4,2,1,1,1,3,5,1,1,1,5,4,1,1,1,2,2,1,1,1,2,1,1,1,2,5,2,1,2,2,3,1,1,1,1,1,1,1,1,5,1,1,4,1,1,1,5,4,1,1,3,3,2,1,1,1,5,1,1,4,1,1,5,1,1,5,1,2,3,1,5,1,3,2,1,3,1,1,4,1,1,1,1,2,1,2,1,1,2,1,1,1,4,4,1,5,1,1,3,5,1,1,5,1,4,1,1,1,1,1,1,1,1,1,2,2,3,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,5,1,1,1,1,4,1,1,1,1,4,1,1,1,1,3,1,2,1,2,1,3,1,3,4,1,1,1,1,1,1,1,5,1,1,1,1,1,1,1,1,4,1,1,2,2,1,2,4,1,1,3,1,1,1,5,1,3,1,1,1,5,5,1,1,1,1,2,3,4,1,1,1,1,1,1,1,1,1,1,1,1,5,1,4,3,1,1,1,2,1,1,1,1,1,1,1,1,2,1,1,1,1,1,1,1,1,1,1,1,3,3,1,2,2,1,4,1,5,1,5,1,1,1,1,1,1,1,2,1,1,1,1,1,1,1,1,1,1,1,5,1,1,1,4,3,1,1,4
|
|
@ -1,2 +0,0 @@
|
|||
342641
|
||||
93006301
|
|
@ -1 +0,0 @@
|
|||
1101,1,29,67,1102,0,1,65,1008,65,35,66,1005,66,28,1,67,65,20,4,0,1001,65,1,65,1106,0,8,99,35,67,101,99,105,32,110,39,101,115,116,32,112,97,115,32,117,110,101,32,105,110,116,99,111,100,101,32,112,114,111,103,114,97,109,10,775,180,473,1346,1189,1553,196,427,788,25,159,204,851,24,1404,91,308,1096,747,278,1185,36,752,57,54,583,570,260,735,1192,72,552,103,693,383,202,78,1050,453,116,333,182,765,60,372,201,291,1642,49,80,918,98,1443,36,577,696,1289,56,220,56,51,550,1666,651,652,1508,70,40,1473,57,1065,32,6,537,1053,315,711,163,476,1006,3,1092,18,1304,237,358,457,888,36,639,39,1051,723,590,1242,210,1217,473,488,1554,729,776,307,375,243,186,436,94,451,1230,495,861,480,28,323,529,92,65,43,564,143,183,81,965,82,168,303,331,99,921,583,1349,182,353,626,150,475,1388,381,539,1190,664,923,1579,564,31,186,171,415,69,82,621,579,636,787,154,384,463,124,213,270,318,16,21,429,1285,1052,755,248,67,1021,20,165,789,7,456,18,1432,1379,3,108,96,40,42,1148,665,526,392,616,405,633,399,152,388,9,1078,159,454,945,330,2,455,288,288,72,313,827,521,939,186,680,253,386,917,317,346,1897,520,662,558,919,31,1141,1025,29,80,601,1001,199,128,1721,1221,367,29,722,186,344,136,415,718,122,7,879,195,1430,250,65,391,1296,154,39,647,861,175,18,448,131,568,322,20,290,828,844,135,622,409,236,40,341,767,31,917,5,335,27,205,63,18,1262,615,1819,291,1263,179,206,686,102,18,483,525,331,303,932,664,337,774,1080,22,177,891,780,523,362,38,219,281,72,861,48,1382,1497,249,343,404,292,1252,1,532,370,421,155,1728,110,1778,804,944,142,1508,155,967,1201,1066,706,613,1222,40,1000,558,616,693,378,124,35,91,514,1445,7,280,775,744,421,236,597,143,380,91,1564,111,1359,711,453,73,247,427,119,182,508,598,514,543,297,182,397,24,1317,107,766,428,877,580,1135,13,266,568,369,570,5,214,1222,150,225,93,1168,7,793,346,17,70,127,734,1428,1513,274,409,1291,498,958,535,37,268,994,165,662,59,125,267,557,28,259,77,1226,588,499,105,15,238,272,272,100,329,642,68,356,782,90,674,608,431,1,442,835,3,780,51,394,146,71,231,582,81,595,921,913,398,831,1107,491,801,371,407,746,1337,196,7,86,427,72,217,3,98,717,1268,991,187,103,256,616,172,125,831,1380,935,281,1534,435,868,1291,51,894,91,527,443,868,1300,72,1108,259,641,381,1103,580,422,310,953,97,8,198,1249,1069,342,953,464,66,648,683,184,702,1488,440,389,408,0,47,1023,45,63,999,131,73,135,256,1586,798,61,43,708,138,500,952,10,170,1287,956,1454,886,1117,405,1064,252,1218,334,316,1116,485,63,336,1218,528,309,86,833,168,955,45,993,841,480,336,512,835,296,285,340,81,1291,61,51,5,284,1114,120,794,1444,889,28,0,327,134,71,1040,230,48,49,837,1191,558,3,26,760,1038,104,320,87,464,270,115,357,277,285,488,1649,477,972,423,524,657,20,395,958,528,13,125,391,90,334,314,1022,1147,200,1357,1092,559,610,193,296,60,188,0,2,277,540,365,79,278,199,1327,573,615,95,677,285,143,182,226,12,661,492,189,526,75,1358,923,228,59,417,535,544,270,1040,197,2,216,1217,372,1034,84,16,725,1798,352,147,290,528,1091,105,476,725,137,474,75,1313,644,92,43,286,47,118,11,865,1316,1464,1189,673,67,612,183,379,309,464,207,31,64,1375,34,413,618,131,1459,178,179,81,245,316,223,230,697,337,977,188,1335,811,163,592,181,93,108,865,112,20,497,986,1124,73,128,96,107,1288,179,229,145,1293,1224,1308,748,768,143,38,33,1842,64,45,1209,984,269,371,1451,876,1372,65,275,173,1569,298,187,91,522,133,39,709,878,2,123,195,1435,1569,482,1047,322,382,796,38,903,24,950,387,510,460,570,499,545,561,158,383,213,978,1329,380,938,280,267,762,841,713,111,357,71,19,121,581,91,177,869,1138,173,14,145,155,21,353,340,1145,113,594,685,91,781,558,500,10,33,300,270,457,675,850,64,49,81,311,906,404,207,176,309,45,855,16,9,881,428,194,300,329,715,985,559,656,66,184,1529,8,1131,610,78,522,338,492,1378,47,163,448,111,700,3,19,796,876,224,212,51,524,273,597,980,0,10,205,8,985,38,876,6,91,435,1273,38,147,214,362,1,95,87,724,1126,807,378,105,89,276,1076,107,552,1082,32,896,202,177,946,753,1106,464,72,61,225,55
|
|
@ -1,2 +0,0 @@
|
|||
543
|
||||
994266
|
|
@ -1,200 +0,0 @@
|
|||
bgafcde gfcd agc ebdgac adfceb bafeg efgca cgdfae cg ecadf | fabgced gc agc cdfg
|
||||
gbdacfe gcabfd cdb dcfba bfacg cgad fadeb feabcg cd gcbfed | bdagcef dcb cdag gbfca
|
||||
dgcbafe dbfca fbaed be cedb gefad dcfeab facdgb eba gbface | eb gadfcbe cfbad gfbeca
|
||||
ebc cb aedbf agcef badecg gaebfc bcgf adbcfge ceabf daecgf | cb bce efdab ecbaf
|
||||
fedbc cebad gfcbd fec gcdfab ecbfga dacgbfe gfed fe gefbdc | bfecag cef egdf fgde
|
||||
bafedc baefg dbfga daegcb gae egbcfa eg cefab fgce decbafg | abdgf cgfe cedgba befga
|
||||
dcba fagbed cgbfed dgfbeac da dag acbgde fcaeg becgd acgde | agd bacd dga gbecad
|
||||
ec aebgcfd fecd bagfec efagd edfgab cgdfea dgcab ecdga eac | ce ec ce gbacefd
|
||||
aegdbfc fe dacbf aefbgd aecgb cdfe ebadcf ecbfa cbfdga aef | dfce fe fcde afebdgc
|
||||
bgaf gcbad cagdfb gb dfbeca degfcb bfadc cfgeadb bdg agcde | fdegacb acbefgd bdg gafb
|
||||
gdecba dcae ec dbfeag bgead dgbce gec cgefab dcbgefa cdbfg | afdbgce agbfde abcgefd ec
|
||||
gacbefd fgbedc egafdc adf fcbae afedb ad bfeadg adbg dfgeb | ad degcfa ad dfbge
|
||||
fadebc baef eadfcg ebgdc eda cfgabd afbdc ea edcab cdgbefa | aefb ead ea ebaf
|
||||
badgecf caefd aebfdc fecbdg fadcg fed de ebad abgecf bceaf | ed gcfebd aebd gfdca
|
||||
bcdae aefcbg fgdea bf cdabegf adcebf fcbd fbead afb begadc | gbcafe faegbc fba eabdc
|
||||
bfcdeg ecd eabgc adeg ed dbaec bcfad ecabfg dbgcfea dbacge | de bdfcaeg ecgfbd bcdea
|
||||
deacf bf eagfdb gfecadb facbeg bfa cbdage abfce fbcg gecab | aebcf ecfagb abegfd bgeac
|
||||
eag dgbecf gdfae caed dfebgca ea ebcgfa dfbag gecfda dgcfe | ae ea deac fcdega
|
||||
edbga egdabc cgfdbe gabfe efcdgab gbdefa fb abdf fbg gecfa | cgaebd cbgdea acgfe begdca
|
||||
cgfedb egbdc agcfd cdagb eabgdf ab abce adb agcebfd dabegc | ba bda abd deagfb
|
||||
fc agfbce fdebg dgafeb ebfdc cbf cfedgba fdcg gcefdb eacdb | gbfaec fgcbed gbceafd bedagf
|
||||
bdcgefa acdfbe ed gbcea cfgbad ecbda edfcag afcbd ead bdef | dfbe de dea dea
|
||||
gfbeca gcefdb fegacd cgbda fbde ed bgedc begcf agdcefb ced | gbacd ced dec bcegfd
|
||||
dgbacf gfabec agd egdaf badcegf ad ecgaf defgb cade dfegca | cdae dga bgcaef ad
|
||||
dcf cfadb bcagd afebd fbgdec egfcbda fcea gfeabd fc ebdfac | gabdc ebfad aefc eacbdf
|
||||
cfgdba fcdab cgfbade adeb afdebc egcfdb de aedfc cfage edf | ed eadb dgebcf cefdabg
|
||||
bcae befga dgebfc fbagce cbefg agb fcedgab ba bdgacf dgfae | beca dcaegbf gab geafb
|
||||
dgafbec fedba cbega aebfdc eabfdg bdgfce edc fdac cd adceb | abedf dfeabg dc gdbefc
|
||||
adegfbc gbedcf cfabd gacedb abcfe fdbacg dgabc df dfga bfd | fdag dbf dafg fd
|
||||
dfbcag ebfcad ed agecdb bfacd egbfa badfe afbcegd aed cdef | afebd ecdf cfed eadfbgc
|
||||
fca dbcaf ebdcf fadbg cdbefa adec ac dacbgfe fbcdge cgefba | ac edca edac ca
|
||||
agdfce cedbfag agc dcbaeg gc bcdga bgdfa cfaebd ebdac cbge | ceadb becg ebadc gc
|
||||
aefbc aecdg efgcad cdebag bcg agfdbc bceag bdge bg fecdgab | bgecda bcdaeg gb caebf
|
||||
cfgebd acedf ag gbad gcfbad acg bgecfa bdfcg gbadecf cdfga | dgba dgcbf gac bgfdc
|
||||
cdgbafe cdgbe gd agde bcaged dfebc geacb cdg bgeacf gbdcfa | efgcba edag gecfdba cgd
|
||||
bcg bcaf cegdaf dfacg dgacb fgcebda bgdcaf efbcgd bc gadbe | gcb bcg caebdfg cfab
|
||||
eg cdgfae aecfd fgbaedc gbdfc facdeb cfegd ceag efg efdgab | fge acefbgd egf efg
|
||||
fcdg gefda cf edabc cedgfa cfa acefd cfebadg gdbafe bgecfa | fc fca cfabged fca
|
||||
ed bcadegf egdfb fgcdb edbafg facbeg abegf deba fadgec dge | eadb ged eadb adfegb
|
||||
bgedc cf cefadg ecbgdf gbfae cbdf fcg ecbgad abfgced becfg | bdcf dbceg fgcbde cdbeg
|
||||
cg gcaf defcag cdefg gdafe dgfabe gec dabegfc bcegad ebdcf | feadg degcf gcaf dcgefa
|
||||
fdeac gdcebf daecbg bgfec fdeagbc gca gecfa aefcbg fbag ag | ga decfagb ag agfb
|
||||
bc fbdc bagecdf gfdcab acdgb dcaeg dbgfa cgbaef ebgfda gbc | bdfc cb cfbd fbcd
|
||||
efagc bafegd abecg eab eb fgbeca gbedcfa bfec fcgade cgbad | abfgdce degacf fcaebg cdabfeg
|
||||
egbfcd afde ecgab fac fa edabcf cbdagfe afbec cfabgd fdebc | deaf feda cgbdfa fa
|
||||
gbafd defca ebcf eb cefbad dcebag dcgfae edfab deb bgedcfa | be deb gdbafce be
|
||||
afdgceb cf gbdeaf acdbfe abcef acf deafb fedgac cdbf cgeba | fac cfdb bdfcae fdcb
|
||||
cfdba ca afbgd eabc cda afbcdeg cfedb ecfgbd efcgad bcfeda | bfgad abec abce caeb
|
||||
cfebad debfacg acgfeb cab fedcb afcdb cdae febcdg ac dgbaf | bac ca faecbgd cgbfae
|
||||
eg dfcegb dge abedcgf facdg bafdgc degacf dafeg agec adebf | egd fegda fedbcag eagdf
|
||||
age gcbad feacb cgbdfae ge gfbe agebc fcadeg cbafde cgebaf | fagecdb bfeg baecg fceabd
|
||||
bfcdge fgcbead ebdgac ba dagbfe gab dabc bcegd gface cebga | cbda gbedc egcbafd gab
|
||||
dbcegfa fadceg fcage bcage gb bdagfc abdec gbfe bgafce bcg | ebfdagc ebfg ebgf egfb
|
||||
gcdefa bagf dgebf bdefc bgcafde dbefga edabg gfe gf dcgeba | fg efg agfb gebfd
|
||||
fabdc gdeabf dag gbace adcgb gd eagfcb gaedbc egdfabc egdc | adgbc bcadf gd cedfabg
|
||||
deagcf ce dfcaeb gfadceb bgade cde daegc cgdafb gadcf efcg | dbaecf fdecbga ce ecd
|
||||
dfcbag abceg db dgcefa dabec bcegdaf cdb bdef defac cfbdea | gdafec dcb febd bdef
|
||||
ead fgceabd edgcaf da fgda fgcea ecdgb cgaed fdbace cbagef | ad eafcdb bfecagd ad
|
||||
ab caefg agbcef efacb gecdfba ecfagd fbdec bdecga cba fgab | eafgc abfg cdagbfe dcageb
|
||||
afbcge ebafcgd dacegb cfbea afbg agc egcfa ag cgdfe bdceaf | adfbceg fagb gfba aecgbf
|
||||
acg cdegbf ecfadg cgdab fcbadg cdbgfae ca agedb cbgdf facb | cdeabfg ca afbc dagfec
|
||||
dca dbfae bagdcf aceg ac afdegc cegfd fcedgb cbdaegf cedfa | dac acge cedgf cfdbgae
|
||||
gdcafe ega cgbfde cgba afdbe bacegd ga begdc dcebagf edgab | abgc ga bacg bdacge
|
||||
begfda gdafce fg gdbf gbaced agf decagbf aebdg gabfe cebfa | fag acdbeg agcdfe dgbefca
|
||||
gfcdbea fecab cbadge afgce gc fgdace fdcg cga eagdf eagbfd | efgacbd gc dgfc dacbeg
|
||||
gdbefc feadg dbagef afd abde gebfd cefga bdgafc da efdacbg | cbegfda adf bade cdgfbe
|
||||
aefbdgc eabcfg cgefa degbf cedfg cd cadg cde fgecad fecadb | dbfegca egcdabf gcda dc
|
||||
baed bcgda abdegc decag ega dgbfaec gacbfe ae cgfde dbacgf | aebd age ea bgdecfa
|
||||
abecg faegcd egfcd efcga cdaf baedgf efa fcbaedg fcgedb fa | afe af aef fa
|
||||
abgfce cbedgaf fbedc eacdfb dcf fd faegcd fecba dfba gdceb | faecdg gdceb dfc gcbde
|
||||
fgce fgadb egdabc edg defbg eg bfced fdbace bdfgeac gbcfde | gdcbfea deg afbedc dgcaeb
|
||||
eg dgcfe efdgab bfdec aecg acbegfd bdcafg adcfg efg daefgc | fge aecg gfe ecagfdb
|
||||
acdfe bedcfg abgec cfeabd aedbfcg fecdag fg fcg afecg gdaf | cdaefg fdag cgf gadcfbe
|
||||
aedc gbdac cbagfe bfdcg gdbfea acb cbgaed ac eadgb gecadfb | gbfdc gbdaec fbgeadc decabg
|
||||
gbc afgdb cfbdga badgef gadbce egabcdf geacf bcdf cb gabfc | fgaec fcagdeb gbcfa bc
|
||||
cfgabd cfdbe eafgdc badcfeg dgfab cbag eafbdg gc dfgbc cdg | fagecd cgd afdbge cg
|
||||
eadcbf fcag gc gbc gadcefb gebad febdgc egcbaf ecbag bacef | dgbfec egadcbf gcfa bcegfda
|
||||
acbeg acgedb eg dgbfce cdagb cgdbaf gaed bafce cfebadg ecg | dbgac eabcf eabfdgc eagd
|
||||
bgefda eacg abdcfe eabcd abegcd ebg cbedg cbfdg dgfecab eg | ecag eg ge afebcd
|
||||
dgecbf bg dfcba abge gadebc edagc bcg ecdfga fbgecad bgcad | cgb gbea ebgcdf gbae
|
||||
dcabg gdfbca debc aed ed fabeg afdecg gbeda caegbd agbfcde | fcbdgea cedb dea efcdagb
|
||||
edbcafg cgaed gc gbdc acfebd cge gceabd abecd afegd bgafce | gc facegbd edbcaf cg
|
||||
gadbce gbdaf acebgf bd abcgfd edfga cdfb gbd cfgab dgafbce | gfdab fdegbac eabcfdg bgcdae
|
||||
eacgf fb cegbdf dgbfca cfb dfba agfcb cgabd ebcdgfa gedacb | acbdg dbaf ceafg bf
|
||||
gebac egdacf fdceg daef af gfa dagfbc fcgbead afgce cebfgd | afg bcage gcdeabf cgfea
|
||||
cdabfg fgbec gcdafe ceafgb egc ec beac febdg bdegcfa fabcg | cafegdb beca ecgbfa bace
|
||||
gda feabdg ebgaf bgdfc bgfcae bfeagdc edab ad adgbf fceagd | gad ad afgbde dfaebg
|
||||
bfc bgfced edbfag fcea cf afgbdce cgbda abgef fcgba aebcfg | bcf efac eacf fc
|
||||
bdeag bgdcf ec ebgdfac gcbde gaec dec cafdeb afdebg cebdag | gcbfd agedb acfdbe ecd
|
||||
befad gd edgbf bcgafd cebgfd abgcef gfd ecgd cgdfaeb ecfgb | cegd cdeg efadbgc egcdbaf
|
||||
gfdbae bc cegbfd gadcf cdaefgb gfbed fbcgd beagcd gbc becf | gedcfba edcagb fbcgdae cfbe
|
||||
ecf cbdaf bdfcaeg fagdec efba bcdfe bfecda gcedb ef cbadgf | ef fbedc dbceg edgfcab
|
||||
cabde ae ecfdba cbdfe faed dabcg cfbgaed gbfcea begdcf abe | adfe aeb cabgd ae
|
||||
gefcabd ecabd gebafc ag ecfgbd gacdbf dfcbg fdga cagbd acg | gebcadf gefbac dgaf dagf
|
||||
bgde efcgd cebgfa dbacgf cgfeb gdc fdaec dfbceg gd fegcadb | efbcadg cgd gbdcfa facebg
|
||||
gefcbd bgfdcea fg dcbag fbgcd fgeb defcag fcg becfad dfcbe | cefbda cfg fegbdc fg
|
||||
bcfed bcfdge aedbfg fad decbfa facge cdba efdca ad dbfagce | eabfgd fadce begfdca gecdbaf
|
||||
edfgbca dbega fdb gfecab fd ebcfda cfda feabd becfa edgbfc | df ebgad cabegfd adcf
|
||||
daegbc fbacg edfg befdac efbcd edafbgc cdg bcgfd fdegcb gd | dg becdf dbeafcg gadefcb
|
||||
egdacf gde ed dfebcag acgdfb cfadg agebdf cgeab gecda dfce | fedagc gabfecd eadgfbc cfgebda
|
||||
dfcea afbde fdgac gefbac eabcdf ace bced ec ebagfd adgbcfe | ce fcdga baecfg cea
|
||||
adebg gdfcae gb acegd abg begc bdaef bfgcda dgaefbc abgdec | bg cbafgd ecbg gba
|
||||
bfacde egfadcb cb fcdea eacbf cedb dcgeaf bgadfc abc ebgfa | adfebc dceb bdcafe efdac
|
||||
faegbd dgfce dcgafe fgadecb bcgd bcfge bfaec gb cdbfeg fgb | aecfb fbg fcgade dafgbec
|
||||
fgacbe fc ebcadg agfdb fdbca cagbdfe cdfe abcde fcb bfacde | cabed cfde bfdac dgbaf
|
||||
defabc gfcbe fea bdacfg adgecf fabce ae aebd bfecdga cdafb | fea ea bgfaced bead
|
||||
dfgae dcafe dce dgebfca abfcd ecab bfcdea gcfebd gafcbd ec | bcdagf cde gbedcfa bfdace
|
||||
cea gaedfb acdf ac ebacgd gefdabc befda cfbae egcfb efcabd | gcaebfd cbaef dfac ca
|
||||
gebac befadgc bedcgf cgb gc eagbdc cebaf cadg bgfaed aegdb | cbg cbg cbgadef acdg
|
||||
gfcdeb bfdegca beac befda bcf dcfga fbcda cb adecfb gbefda | fbc dbafc cbf cfb
|
||||
cbdfeag becagf acgeb be cgbda gfcdbe efba acfeg ecb eadgcf | aebf eb bagcfe eb
|
||||
febg aecbdg fedacb ecg ge fbgaedc dfgce afcgd fcbed efcdgb | aedcbg baegcfd ecg bedcf
|
||||
bcfedg gdbcae febd fcbag fgbcd bd ecdgfa dbc fdcagbe gdcfe | efgbadc fcbedg abfecgd cgbedf
|
||||
feagc cb dcgeabf fadbgc cgfdae fbdea feagcb bcafe cbeg bac | bgce bc cgadbf cba
|
||||
efagbd dageb dcgbeaf gc acg gdecab gecd fdbca gbcfea acbgd | eagbd egfabcd gfbace gca
|
||||
ae cgae dea eacgfd fadgc gfebd afdcbe dfeag acbfgd dacbgef | dgbafc cbdfgae ae ead
|
||||
egb gcfe abcfdeg begfcd abcdfg dabec eg bdfcg edgcb bedagf | bdecg beg gbdcef dbeac
|
||||
fcgae dfcebag aefdb geacbf cda dagbcf cd adcfe fedacg gdce | bcdafg adefb fdeba gecbfa
|
||||
afegd gadfb fcgadeb gbcade gdabef cefgad dfbe bdg fagbc bd | dabegc bfgca bd dgb
|
||||
dfceba faecd bd afbedgc ebad fcadb bafgc dcb efgdcb gfaedc | faedc bead egcdbaf bd
|
||||
cgb bdcfeg cg gdbeca cgef gdbcfea febdg fdcgb dafgeb bacfd | cgfe cgb gc gfec
|
||||
cadgfb cefdbag cg begacf dfgbea bgc adgbf bgcad fdgc eabcd | cg fgceab ebdacgf ecbdgaf
|
||||
bgdefc decfg cfedga cefgb bfdcea edgfacb bgcd fegba ceb cb | cfgbe dcaefg cbgfe dbcg
|
||||
gefbda acde gcbaf cd cfd bdcgfae daefg gdcbfe cgefad agdcf | gcebafd efgcda cfd aecd
|
||||
gedfc cead egbfda fgcdabe de fcgea gfdbc deg cagdef gebacf | deg bfgead gdfbc gde
|
||||
fbgae bfecg dbcaef gdcaeb cbfdge gbc decgbfa edbfc fdgc gc | gc gbcdef fdcg gfcbe
|
||||
fc caf cadbe dgabfc gebdfa fecg fagbe cebaf acbegdf cgabfe | egcf ceagbf gcfe ebgafc
|
||||
abfcd cgbfa bcgafd gadefc abfde cdf dc agfbced cbegfa gcbd | cd cfd fgeacd cdf
|
||||
bdgae gfbce cbagfd gedbcaf ebcgd gbcefa dc fcde cegdfb dbc | dcegb fgdcbea deabcfg bdc
|
||||
ebcagf df bgcdefa fdceba cgdf dbacgf eadbg afd abgcf gabfd | ceagdbf dagcbf fd dcfbaeg
|
||||
dga cadbgef efbcgd bgdca eacd cedbga gdbec gdeabf fbacg da | dag adg edac edgcb
|
||||
febcg gbadce aedbcf acbed cbgae cag gadb degbcfa ga fcgdae | bgad abdgfec acbed acg
|
||||
gdcaf dcbfag gdefa abcdg bcfg cf fedgacb dbaegc fcedba afc | cf afc gcfb eafdgbc
|
||||
gdcaef gcabfd bcefgda cde gcdfb gbecfd ec dfaeb cefbd egbc | egbfdc ce gbdcfa afbcgd
|
||||
fdea fga fa adcgbef abfcge gbeda fagdb abedgc cgbdf bdefag | fa gaecfb beadgc cbfgd
|
||||
ba gcbafd decgba bfga fbadc bda dfbeacg ecfgbd cedfa fdbgc | gfab gbdfc adb ba
|
||||
bd ecdgab aedfg bde fbcae decfba cgafbe fdeab dbfc fdgceba | db dbe cdfb bdgfaec
|
||||
bd gcefbd ebcd dafbgc ebfgd decgaf edcfg fbd fbaeg gafcdbe | cbeagdf cebd cedb cedb
|
||||
edagf cdaefbg ead efgdb bgafed cfdag bfea dabgce dfbceg ae | gcafd feab dgfca feba
|
||||
gecfda bgcdf ba abd edgabf bcdeaf gedfa fdbga baeg abegcdf | ab bad bda fgebcda
|
||||
egadb bec dbefga cbafg cageb ce ebdgca dceg gdebfca cfbead | ec ebc egdc ecb
|
||||
cbgfe fadcbg agde cbdge egdacb degcabf bed faebdc ed dcabg | eadg facdbe bcdeg debfac
|
||||
fabe fb bgf edcgaf bgacd bcfegd fcdegab adgef afbdg gbfade | bfg dbcgfae edacbgf bf
|
||||
bcdfe becgd cbafegd decag geb dgfb bfcade dgcefb bg gfbaec | bdgce gb dcbge gdfb
|
||||
egcadf bfg fgbdac faedg ebaf gcedb begdf fb adfebg cafdgeb | faedbcg bafcgde bf becgd
|
||||
edafgb ecbgd gcdfaeb ef gbfadc cgfade gef fdegc fgcda efca | agfecdb dcabgef ef dgcaf
|
||||
cbdgea fegcad bagdc abdfgc age gebac afbcdge egbfc adeb ea | ae ega ecagbd gbacd
|
||||
ecdfb edafbc fe afdcb efc degcb aedf acbgfd ecgfab fecabdg | fe dbegcaf fe cedgfba
|
||||
edbfgc caeb ca cbdafg bcdge bgcdae edfga eacgd gca cgabfed | facebdg ca aedbgc ac
|
||||
gfeba aegc cbfega ea bea dfgbe edfacgb fadgbc gbafc aefcdb | gbecfda bcdfag gcea afcegdb
|
||||
fgcea dc egfdba cdafe gfdecb fbaedc ebdfa dacb bdafgec dec | ced bcfdaeg cefda fagcbed
|
||||
dbefa defacg agd dcbfg bdfagce ga efgbdc abgc fdgab bacfdg | cbga dga gedcfab fdabcg
|
||||
eacbf eac dfagbce cfga fbgea ca bfced agebdc fbedga fcbega | dabfgce gfca ebfacg gbaecf
|
||||
cfagb cgfdea gdc agfcbe fdeacbg bcfdg dg badg fdgacb bcdef | cgd gfacb gd gdba
|
||||
cfga gbadef decabfg cbged baefcd ca cda dbagf fdbcag dbgca | afgebdc bdgeaf gafc cfag
|
||||
cgfbd cdafgb gbcead dbg afdb bgecf adfcg ecbgdfa bd gdacfe | fgacd cgdfa bdaf dbg
|
||||
abf fb febd dbafg febcga gbead egdacb fedgba fbagdce gdcaf | bf fb dbceafg fba
|
||||
fd dgfabe ecafdg deabcg cbefa fed dbgea bdefa bgdf dbfgeca | fde bdfg fdgb gfeabcd
|
||||
fgeadb abfed dgfbcea bafgd agcfd gfb bdfaec bg dgbe cegbaf | egdb fegadbc dcgaf bg
|
||||
fdabc acfbgde dg fcage cdfgab dfebag dga gdafc cdgb eafbcd | gfcad aegdcbf dag afbdc
|
||||
dbfe efdag fgdcae cgbfaed bgfead acebg fb bgf egabf abfcdg | ebdf gfb ebfd fgabed
|
||||
bafegd egcfadb fbc bc fcebgd becaf afbed agecf beacfd bdca | cb dbca cfb afgbcde
|
||||
gbefdc bfead gfcdab gbedca fc cabegdf bedfc fdc cefg cgbde | fdbceg cgfe fc bdcaefg
|
||||
fg dbfea fedagbc cageb aecfdg dfgb dbfaec gafbed begaf gaf | gfecad dgcfea dafeb gfbd
|
||||
dabfg eb egacdfb bfcdga faedc gdeb fbagec aeb bgefad dfeba | bafdcg gfbda gebd be
|
||||
adb dgeabc bfdg gaecfd afdgc cbdgfa bd dcgeafb dafbc bafce | bd fcagbde defagcb dbfg
|
||||
fge bagcf dfaebg fgebc eg cdeg fabcedg bedcf dfcegb acfbde | egcd ecgd cebafd cgdaefb
|
||||
bafdgc gecabf caegf ae beaf gfacb decgf cfedbag aec cdabeg | dcfge ae egcdafb eca
|
||||
fcgba ebgaf agefd agcdfb beac gdbcfe beg bcdfgae gacfbe eb | cfebgd abecdgf ceab abcfdge
|
||||
abcgfd bac feabd adcgeb fcgb bc debgcfa fbdac gceafd fagdc | fbcg gcfad afbed cfbda
|
||||
afdbegc dea abegd agecbd afbgdc dgbfe cabgd afcbed ceag ae | daecbfg cdbag acge ea
|
||||
ebdcg cbfg cdgebf bge adbec eabgdf baecfdg fgadce gedfc bg | dcbae fbcg beg gfbc
|
||||
cfbga cefabg ebfca abeg ae bcedfga gbacfd eac bdefc dcafge | abge fedbc bacgf eac
|
||||
eb aedcg dbfcge cegdbaf gfbe bed dagcbf dacebf dcfgb dbceg | gbef dbe fegb eb
|
||||
cgfe ced dgeba ce cegad abedcf cdaefg cfagbd cadfg gbcedaf | ecgad gcabefd dfbcgae ce
|
||||
dbagc afdc dgfaeb bcfage gbedfac cafbdg cdgeb ac cab gdafb | cab dafbcg dacf acdgfeb
|
||||
dgbae bfa eafgb bafegd fgaec bcfadg fb dbfe egbadc gbecadf | cdegbfa dagfcbe fdeb fab
|
||||
be aecgdf gbdacef bagfc bdef beagf beg dbefag gedfa cbgade | be eb afegb beg
|
||||
cfdagb ac gcfdae cbad bfgda bcfedga begcf afc ebafdg cfbga | deagcf abdc ca cagfb
|
||||
eg efdbga adbcfg ebfcga aefgd bdfga adcbgef defac gbed gae | edbg gedb bfdeag dbcgaf
|
||||
bacegf gbfca cfa ceab gafeb ca gcfdb gadfec dbafge gbdfaec | caf fbgedac fca afc
|
||||
fbagde cbeg afecg gdaecbf fedcga gab efacbg gb acbfg cfdba | gba ecbg agb abgcf
|
||||
abfg dafcgb gcafd bdcgaef ab cba ebdcf bgdaec cfaegd fcbda | acb ecadbg cgdabe fgab
|
||||
agcbd cegdba feagb fd daf gbfad bacdfg cgdfabe dcefab fgcd | df dagbc fgcd fd
|
||||
gdfeabc bcd debaf cb gedfab bcefd edfgc bdceaf aecb cdgbfa | ebac beac cbea abce
|
||||
cbgdef eg beg dbgfc bfgcead gbefd efcg edgbca eabfd acbfdg | gbe gbe cefg gbe
|
||||
fedg begcad gdb bafdge gd egbcaf gdbaf bfacd eacgdbf eafgb | cbefag baegf gefcdab bedgac
|
||||
gbce dcafgb agfdceb efdac acg agcfe aefgb befagd cegfab gc | fbedgac abdefg cga cag
|
||||
gabc bceadf agfcd agd ag fcdgbea gabdef gedfc dbcfa agbfdc | gacb gad bgceadf cbgafde
|
||||
afedc fabced gfcbed feb cegdbaf dbfa ebfac dacfeg fb gbace | feb afdb ebf acfde
|
||||
cbed edgcf ecabdfg ceg cfbgd abgfdc gebfdc ec efbagc gedfa | ec decb ecdb gec
|
||||
egd gfbeac gedcb de dabgfe dcfbg cbefdag eadc dcegba acegb | ed adgfceb gde abcged
|
||||
efadcgb fbdce fagedc agebfd gbafe abedf da bgad ead ceagbf | efagb ecdbf ade aebcgfd
|
||||
cgeb bfaed cbedga cbaed bc bca afgcbd dgface bgfecda decga | fgadcb bca dabfe cab
|
||||
dgaec deagcf egf cdeabg abgdf gdfceab dfcbeg gfead efac ef | agebcd efdbcag aefc bgefcad
|
||||
fbeac gebcaf efa fgce bgfdea dgbcfae gcbdea adcbf ef egacb | gebfacd bfadcge ef eagbc
|
||||
acdbgfe adfg edfcbg efacb egacf gca dgaceb egdcf ga gefcda | fdga cfgae cga ga
|
||||
dfebcg gdaebf dagcf gbaecd dcgebfa bf cfbe bgf bgdce fdbgc | cgbefd bcfe gbf ecbf
|
||||
dcafeg ca acf fcdeb abcfdge facdgb bfagd dfaegb bagc dfbac | dfabgce dfaegc gbafde bacg
|
||||
cgefb cbe cfab afdbeg cb faebg gcfde cefbag ebadgc afdbgec | egbdcfa cbe cafb fecagbd
|
|
@ -1,2 +0,0 @@
|
|||
468
|
||||
1280496
|
|
@ -1,100 +0,0 @@
|
|||
9821016789345689876545245989999932987654349769898765104567898765634567899765432123788999891045698701
|
||||
7632145894234599987432134567898799999979498956789854323458999854323456789898321094567988789234987612
|
||||
6543234789345987654321015778987678987898987545678987634569899843212349899987432989679875678949896543
|
||||
7654345678956798765692126789854567896587898621567898545698789765103478999876549878998754599998789654
|
||||
8765496789987899976989238898763459965456999533478999768789678973212567899989698767898765989987678967
|
||||
9876787898798989899879345997652378954345987644567899878893467895323878989998987658999879878876567998
|
||||
6987898987689876789768959876543789993234599785698999989912457895456989878987898767899998767765456899
|
||||
5798999996579765878957892987984578989356679876789998692101567896569999765496789878989789856312345788
|
||||
4569899987498654567898901499876789678967889987896987543213456998778998954345678989775698543201234567
|
||||
3659789986329943458999212345987894569898995498945998764394967899989987893236789998664987656312345678
|
||||
2545678965439892347895425457998913456789654329434898765989898901298546789959899899543498765453456789
|
||||
1234568896798789456789434569879324599998993210125679899876789312987634567892998798992379879567867899
|
||||
0123456797987689967897545698765434987876789321234567989865695459896523498921987657989467988789878978
|
||||
1294968999996579898998656789876549976745898934545679876974489598765434789439876545878989499999989767
|
||||
2989899998765458789998767897997698865434567896898789995432378999876555678998765434567894345678997656
|
||||
9878789987654323678999898956798987654323456987899893496321267899989666789019896325679921234899876545
|
||||
7654678998765412567899999543459876543212369898934912985432456789999879894323998437789210345799985632
|
||||
6543568999654323456999897632498765432101458799329899876543569899985997995439896558994351456989994321
|
||||
9854567898798654567896789321239878543212345679498798997854679999874356789998797667895942349878989990
|
||||
8767698999899766878925459210123987654323457789989657998965989398765234567895689978999893598769878789
|
||||
9878989896999987989412368991234598765454769898878945899876793219876347698924567899998789699754965679
|
||||
7989876765788998994323456789947699876767899987653434678987894101987456999213345978987678987643434678
|
||||
6799995454567899987434569896899789989878978998762123789098999919598567895101234569876549876542123689
|
||||
5678989323456799876565678935678993497989767895421012392129998798439878963214395678987634984321034599
|
||||
4895678910167976987676789124569012976593656789532323679245987656522989954323689989876545695432234569
|
||||
3434799321279875498787891013689929876432545678993434568956798743210197895434567899987656987954345778
|
||||
2223789534569989329898999124567898954321434567989546979767898654321356789545679989998967899876456989
|
||||
1012578945678998910949678935678987895910125789879999899898998765432459997676989878999878956987867891
|
||||
2123459656989987921234568945989876789891234598767889789999649899543567898787894567898989347898978932
|
||||
3436578987899976899499689656798765676799345987655678678998767988999878939898923456957893236799989893
|
||||
4547678998999894988988998767998654545678957898743244569759889876789989923969212367898994345689998789
|
||||
5789789349987673976567899879876543234569768997542123458945998765678998799654323459999987658789989656
|
||||
6998993299876542987678943989995432123456979876543764567896987654589987678976434598989998767898978942
|
||||
9887894986987431099789992199986543434567895998654876678929876543498943569996565987878999878987867891
|
||||
8656789875698549129897889249897696545678934569765987989210987654567892456789699876569689989876545990
|
||||
7645878954987678998965678956798987858789124579876898999391998765678921239999987943489597898787434689
|
||||
5434567893298899987654667897899298767891035899989929998989899877889210198789876542123456789632123599
|
||||
2123678942109959876543456989999019888989186789891012987678789988994323987678998753244897896521012678
|
||||
1034589543212345987632345678978999999679997898752129876567679999995439876567899894556789965432123789
|
||||
2137897654323459876321234789567989656567898999643498765434567999987656985498956965678890986563234599
|
||||
3246789765434598765430125897679878643456789998756569876323456789598767976989999876899921987784346789
|
||||
4557999876545679898641236998789966532345899899867891987212345895459899899876989987999932398765659897
|
||||
5768954987786789989752347939899854321236998789878990195323467932378998789765678998989893459876789956
|
||||
6879543098899899879765458949998767432347897678989989996934589549999987678954367899876789598987892345
|
||||
7889632129978999769878569998769876543456976456799879889895697698789996589895256989865679987798931234
|
||||
8996543234567898754989678999654987656567965345898767679789899789678985456789345679654598765679892349
|
||||
9987656745678987643298789998743298777678954234987654545699967998799876789895458989765987654566789598
|
||||
9898787898789999732109898999856899988989432129876543236789656899893997897987667899879996532345699987
|
||||
8789898989898998743412967899987967799996573236987664127894346789965698976498788921989987621234789876
|
||||
7678949678987987658583456999998956667899794345698543234993237899876989899329899990199998710123898765
|
||||
7543234567896798867678967898999345556798989456987656786789379912999876788934998789239879823939999654
|
||||
7654949698965679878789989987893212445987678998998767897895467902987665677945987698998765439898998743
|
||||
8969898989754567989896899876789901239879567899999878998996598929876554566899876567899876598767897632
|
||||
9997767879543456798945698765899892398768456789898989879987679939875432345789985458912998987656789541
|
||||
9986556568912345987656987654356789987654345698767694767998789898954321234679876345793989876545997679
|
||||
8765432457893959898979876543245678998743256789654543459899899767899434348789965457989878976434569898
|
||||
7654321348999898769899985432123899987654569896543232498789987856798995679892396769876767994323498987
|
||||
9874210156789787656789876543012790198767698989692101987679876543456789989921987898765456789434987876
|
||||
1984321347896576545699987654125691239988987678989919976567985532345999897899598999876345699949876545
|
||||
2995432348954321034989998876234789545699876563479898765459874321248789766998439998765236789899975434
|
||||
9876543456796542129878969984345897676798987432365679876398765210123678955987645989854101896789964323
|
||||
6987678567897656298767456798767898987987654321234795988987654321234569543499659876543212345899873210
|
||||
5498987678998967987658345679878999898999865672347894399598765432345678932398767997654345456998754321
|
||||
6399798789899879876543238899989998789999876989456789212459976576556789543459898998785456767898765452
|
||||
7987659896789989998630127678999989679899987896567893101969897677679897659569989129886578898969876599
|
||||
9876545965678999987621234569999876567789998999879964239898798988989998998998678998997889949658987987
|
||||
9987631274798999876542355679987654345678939989998999398787689899196569896987589897698995432347899876
|
||||
9999820123457899876543498789898543234599649878987678987654578789023498785876456797549876545756998765
|
||||
8987634799598910987656569898765455125989998769876587898743434679234987654212356789432987659867987654
|
||||
7898545678919999998767898999874321039878898654322456987652123678949799765101347894321098792998996543
|
||||
6999657889209878999898987598765432398767789863210345698543234589998652976432456985432129891239987432
|
||||
5878968994398767892999763459876543987654598754321239789654345678999430987543479876549298910129876521
|
||||
4659878965943658991987642398989656798543459865434678998766556789987521987674569989998987621234987632
|
||||
3234989879892345789986543987898767929432123998765989659877677894987432398989678999887996545345698783
|
||||
2123699998789496892397959876789878912949234899876796546989788943596543459998789898656989656957989894
|
||||
1014568987678989989998999765678989109898946798987895432399899912987896578959895697645678969898979965
|
||||
2123456798545678979899987854569993298767958897699976541034987893498997989543934985434567899789569876
|
||||
3654567899434989656789876543458954987658969989549865432123456794579989895432129876323458987693456987
|
||||
4765878998745699967895998652367969876549878978934976543234569896989877789541034965434569876532345698
|
||||
5878999987658999878944349763456893989689989569019987894345698999998765678952199876545679986321236789
|
||||
7989398798867989989431239854567892199789893459198898765467987898987654567893988998756798765445789899
|
||||
9895497659978978998532345967678943239897654598976789876879886767897653678999877899767899876556895978
|
||||
8789989431299567897644459878789765456998765987865678987998765458975542768998756789898954987667954567
|
||||
7655978990123456789765567989899876769999979896754569899019876769654321658789546678969993298778943458
|
||||
6544567789236767899899698998910987878989998765443475698998989989643210145678934589654989109899432346
|
||||
5432345678945988912998999987891298989878987654321254567897694498754321234789123498799878912954321234
|
||||
4321234989856789923987899876789349998969899863210123458976543239865632355678934599988767899765432345
|
||||
5430129899767899899876798765478956997658789654431734567899854129876548766789545989877656778998545458
|
||||
4321239788978998798995459854357899876545678966545675678998765934987656878999769878965437567987657867
|
||||
5432998657899987656789345965456798765434567899656789789219999896798787989659898767894323456898768978
|
||||
9659876545699986547893239879767989854323456998767890998909878789899898997545999656789214356789899989
|
||||
8769985434589997656792123989979876543412397899878921457898767679989949876434398769898901234589998991
|
||||
9898767124567998767891012995989989872101289998989762345987654568975439877321239898987892345678987890
|
||||
9949656012369899889952129894398799965432378987899843569898743678954321965452345987676789657989996789
|
||||
9239743223456789996543298765219679878554567896987654698769832367895932987565459976585778967898965678
|
||||
8949854337567894987964987674101567987669878965498765987654321456789793498976798765434567898987874567
|
||||
7698765445878943299899876543212346798778989874349876799776532368995689569987998654323456999876553656
|
||||
8549977656989654998754987894334587899899498763256997899897543479434568978999876543213797898765432347
|
||||
7632988767899879879543498985455679945954349854367898965999654567925678989456988654435678999897321055
|
||||
6543499878921998765432459876576789656891298768478999654298776778936899994345699766576789998765432123
|
25
2021/day1/day1_rs/Cargo.lock
generated
Normal file
25
2021/day1/day1_rs/Cargo.lock
generated
Normal file
|
@ -0,0 +1,25 @@
|
|||
# This file is automatically @generated by Cargo.
|
||||
# It is not intended for manual editing.
|
||||
version = 3
|
||||
|
||||
[[package]]
|
||||
name = "day1_rs"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"itertools",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "either"
|
||||
version = "1.6.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e78d4f1cc4ae33bbfc157ed5d5a5ef3bc29227303d595861deb238fcec4e9457"
|
||||
|
||||
[[package]]
|
||||
name = "itertools"
|
||||
version = "0.10.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "69ddb889f9d0d08a67338271fa9b62996bc788c7796a5c18cf057420aaed5eaf"
|
||||
dependencies = [
|
||||
"either",
|
||||
]
|
|
@ -1,5 +1,5 @@
|
|||
[package]
|
||||
name = "rust_2021_1"
|
||||
name = "day1_rs"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
|
@ -1,4 +1,3 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use itertools::Itertools;
|
||||
use std::io::{self, BufRead};
|
||||
|
||||
|
@ -19,7 +18,7 @@ fn main() {
|
|||
count_increasing(
|
||||
numbers
|
||||
.windows(3)
|
||||
.map(|window| window.iter().sum::<usize>())
|
||||
.map(|window| -> usize { window.iter().sum() })
|
||||
)
|
||||
);
|
||||
}
|
2
2021/day1/vhdl/.gitignore
vendored
2
2021/day1/vhdl/.gitignore
vendored
|
@ -1,2 +0,0 @@
|
|||
day1
|
||||
workdir/
|
|
@ -1,11 +0,0 @@
|
|||
configuration day1 of sim is
|
||||
for aoc_stdio
|
||||
for dut_inst : dut
|
||||
use entity work.top generic map (
|
||||
MAX_INPUT_DIGITS => 6,
|
||||
OUTPUT_WIDTH => OUTPUT_WIDTH,
|
||||
STEP => STEP
|
||||
);
|
||||
end for;
|
||||
end for;
|
||||
end configuration;
|
|
@ -1,8 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
source "$COMMON_DIR/vhdl_run.sh"
|
||||
|
||||
cd "$(dirname "${BASH_SOURCE[0]}")"
|
||||
|
||||
DUT_OUTPUT_WIDTH=12
|
||||
test_sim day1 top.vhdl
|
|
@ -1,55 +0,0 @@
|
|||
[*]
|
||||
[*] GTKWave Analyzer v3.3.109 (w)1999-2020 BSI
|
||||
[*] Wed Dec 1 13:50:21 2021
|
||||
[*]
|
||||
[dumpfile] "/home/xiretza/dev/advent-of-code/2021/day1/vhdl/workdir/sim1.ghw"
|
||||
[dumpfile_mtime] "Wed Dec 1 13:48:36 2021"
|
||||
[dumpfile_size] 235598
|
||||
[savefile] "/home/xiretza/dev/advent-of-code/2021/day1/vhdl/sim.gtkw"
|
||||
[timestart] 11375200000
|
||||
[size] 1920 1035
|
||||
[pos] -1 -1
|
||||
*-26.627251 11673700000 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
|
||||
[treeopen] top.
|
||||
[treeopen] top.sim.
|
||||
[treeopen] top.sim.dut_inst.
|
||||
[treeopen] top.sim.dut_inst.window.
|
||||
[sst_width] 221
|
||||
[signals_width] 173
|
||||
[sst_expanded] 1
|
||||
[sst_vpaned_height] 296
|
||||
@28
|
||||
top.sim.clk
|
||||
top.sim.reset
|
||||
@420
|
||||
top.sim.char_in
|
||||
@200
|
||||
-
|
||||
@420
|
||||
top.sim.dut_inst.window[0][0]
|
||||
top.sim.dut_inst.window[0][1]
|
||||
top.sim.dut_inst.window[0][2]
|
||||
top.sim.dut_inst.window[0][3]
|
||||
top.sim.dut_inst.window[0][4]
|
||||
top.sim.dut_inst.window[0][5]
|
||||
@200
|
||||
-
|
||||
@420
|
||||
top.sim.dut_inst.window[1][0]
|
||||
top.sim.dut_inst.window[1][1]
|
||||
top.sim.dut_inst.window[1][2]
|
||||
@421
|
||||
top.sim.dut_inst.window[1][3]
|
||||
@420
|
||||
top.sim.dut_inst.window[1][4]
|
||||
top.sim.dut_inst.window[1][5]
|
||||
@200
|
||||
-
|
||||
@28
|
||||
top.sim.input_valid
|
||||
@22
|
||||
#{top.sim.output[11:0]} top.sim.output[11] top.sim.output[10] top.sim.output[9] top.sim.output[8] top.sim.output[7] top.sim.output[6] top.sim.output[5] top.sim.output[4] top.sim.output[3] top.sim.output[2] top.sim.output[1] top.sim.output[0]
|
||||
@28
|
||||
top.sim.output_valid
|
||||
[pattern_trace] 1
|
||||
[pattern_trace] 0
|
|
@ -1,71 +0,0 @@
|
|||
library ieee;
|
||||
use ieee.std_logic_1164.all,
|
||||
ieee.numeric_std.all;
|
||||
|
||||
use work.util.all;
|
||||
|
||||
entity top is
|
||||
generic (
|
||||
MAX_INPUT_DIGITS : positive;
|
||||
OUTPUT_WIDTH : positive;
|
||||
STEP : natural range 1 to 2
|
||||
);
|
||||
port (
|
||||
clk : in std_logic;
|
||||
reset : in std_logic;
|
||||
|
||||
char : in character;
|
||||
input_valid : in std_logic;
|
||||
|
||||
output : out unsigned(OUTPUT_WIDTH-1 downto 0);
|
||||
output_valid : out std_logic
|
||||
);
|
||||
end entity;
|
||||
|
||||
architecture arch of top is
|
||||
function WINDOW_SIZE return positive is
|
||||
begin
|
||||
if STEP = 1 then
|
||||
return 1;
|
||||
else
|
||||
return 3;
|
||||
end if;
|
||||
end function;
|
||||
|
||||
type number_t is array(MAX_INPUT_DIGITS-1 downto 0) of digit_t;
|
||||
type window_t is array(WINDOW_SIZE-1 downto 0) of number_t;
|
||||
|
||||
signal current_number : number_t;
|
||||
signal window : window_t;
|
||||
|
||||
signal window_count : natural range 0 to WINDOW_SIZE := 0;
|
||||
begin
|
||||
process(clk)
|
||||
begin
|
||||
if rising_edge(clk) then
|
||||
if reset then
|
||||
output <= (others => '0');
|
||||
output_valid <= '1';
|
||||
window_count <= 0;
|
||||
elsif input_valid then
|
||||
output_valid <= '0';
|
||||
|
||||
if char = LF then
|
||||
if window_count = WINDOW_SIZE then
|
||||
if current_number > window(window'high) then
|
||||
output <= output + 1;
|
||||
end if;
|
||||
output_valid <= '1';
|
||||
else
|
||||
window_count <= window_count + 1;
|
||||
end if;
|
||||
|
||||
window <= window(window'high-1 downto 0) & current_number;
|
||||
current_number <= (others => 0);
|
||||
else
|
||||
current_number <= current_number(current_number'left-1 downto 0) & char_to_digit(char);
|
||||
end if;
|
||||
end if;
|
||||
end if;
|
||||
end process;
|
||||
end architecture;
|
|
@ -1,30 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
|
||||
if __name__ == '__main__':
|
||||
syntax_check_score = 0
|
||||
autocomplete_scores = []
|
||||
for line in sys.stdin.readlines():
|
||||
stack = []
|
||||
corrupted = False
|
||||
|
||||
for c in line.strip():
|
||||
if c in '([{<':
|
||||
stack.append({'(': ')', '[': ']', '{': '}', '<': '>'}[c])
|
||||
elif stack.pop() != c:
|
||||
syntax_check_score += {')': 3, ']': 57, '}': 1197, '>': 25137}[c]
|
||||
corrupted = True
|
||||
break
|
||||
|
||||
if corrupted: continue
|
||||
|
||||
autocomplete_score = 0
|
||||
for c in stack[::-1]:
|
||||
autocomplete_score *= 5
|
||||
autocomplete_score += {')': 1, ']': 2, '}': 3, '>': 4}[c]
|
||||
autocomplete_scores.append(autocomplete_score)
|
||||
|
||||
print(syntax_check_score)
|
||||
autocomplete_scores.sort()
|
||||
print(autocomplete_scores[len(autocomplete_scores)//2])
|
|
@ -1,8 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_12"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
|
@ -1,59 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use std::{
|
||||
collections::{HashMap, HashSet},
|
||||
io::{stdin, BufRead},
|
||||
};
|
||||
|
||||
type Point<'a> = &'a str;
|
||||
|
||||
fn walk<'a>(
|
||||
connections: &HashMap<Point<'a>, HashSet<Point<'a>>>,
|
||||
visited: &[Point<'a>],
|
||||
extra_cave: Option<Point<'a>>,
|
||||
from: Point<'a>,
|
||||
) -> usize {
|
||||
let mut res = 0;
|
||||
|
||||
let mut visited = Vec::from(visited);
|
||||
visited.push(from);
|
||||
|
||||
for target in &connections[from] {
|
||||
if *target == "end" {
|
||||
res += 1;
|
||||
continue;
|
||||
}
|
||||
|
||||
let is_uppercase = target.chars().all(|c| c.is_ascii_uppercase());
|
||||
let was_visited = visited.contains(target);
|
||||
|
||||
if is_uppercase || !was_visited {
|
||||
res += walk(connections, &visited, extra_cave, target);
|
||||
} else if extra_cave.is_none() {
|
||||
res += walk(connections, &visited, Some(target), target);
|
||||
}
|
||||
}
|
||||
|
||||
res
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let lines: Vec<_> = stdin().lock().lines().collect::<Result<_, _>>().unwrap();
|
||||
|
||||
let connections: HashMap<Point, HashSet<Point>> =
|
||||
lines.iter().fold(HashMap::new(), |mut map, line| {
|
||||
let mut parts = line.split('-');
|
||||
let p1 = parts.next().unwrap();
|
||||
let p2 = parts.next().unwrap();
|
||||
|
||||
if p1 != "end" && p2 != "start" {
|
||||
map.entry(p1).or_default().insert(p2);
|
||||
}
|
||||
if p2 != "end" && p1 != "start" {
|
||||
map.entry(p2).or_default().insert(p1);
|
||||
}
|
||||
map
|
||||
});
|
||||
|
||||
println!("{}", walk(&connections, &[], Some(""), "start"));
|
||||
println!("{}", walk(&connections, &[], None, "start"));
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_13"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
nom = "7.1.0"
|
|
@ -1,83 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use std::collections::HashSet;
|
||||
use std::io::{stdin, Read};
|
||||
|
||||
use nom::bytes::complete::tag;
|
||||
use nom::character::complete::{anychar, newline, u32};
|
||||
use nom::combinator::{map, map_opt};
|
||||
use nom::multi::many1;
|
||||
use nom::sequence::{preceded, separated_pair, terminated};
|
||||
|
||||
type Input<'a> = &'a str;
|
||||
type IResult<'a, T> = nom::IResult<Input<'a>, T>;
|
||||
|
||||
type Point = (usize, usize);
|
||||
|
||||
fn point(i: Input) -> IResult<Point> {
|
||||
separated_pair(map(u32, |i| i as usize), tag(","), map(u32, |i| i as usize))(i)
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, PartialEq, Eq, Debug)]
|
||||
enum Fold {
|
||||
X(usize),
|
||||
Y(usize),
|
||||
}
|
||||
|
||||
fn fold(i: Input) -> IResult<Fold> {
|
||||
map_opt(
|
||||
preceded(
|
||||
tag("fold along "),
|
||||
separated_pair(anychar, tag("="), map(u32, |i| i as usize)),
|
||||
),
|
||||
|(dimension, position)| match dimension {
|
||||
'x' => Some(Fold::X(position)),
|
||||
'y' => Some(Fold::Y(position)),
|
||||
_ => None,
|
||||
},
|
||||
)(i)
|
||||
}
|
||||
|
||||
fn input(i: Input) -> IResult<(Vec<Point>, Vec<Fold>)> {
|
||||
separated_pair(
|
||||
many1(terminated(point, newline)),
|
||||
newline,
|
||||
many1(terminated(fold, newline)),
|
||||
)(i)
|
||||
}
|
||||
|
||||
fn do_fold(points: impl Iterator<Item = Point>, fold: Fold) -> HashSet<Point> {
|
||||
let transform = |x, n| if x < n { x } else { n - (x - n) };
|
||||
points
|
||||
.map(|(x, y)| match fold {
|
||||
Fold::X(n) => (transform(x, n), y),
|
||||
Fold::Y(n) => (x, transform(y, n)),
|
||||
})
|
||||
.collect()
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let mut data = String::new();
|
||||
stdin().lock().read_to_string(&mut data).unwrap();
|
||||
let (points, folds) = input(&data).unwrap().1;
|
||||
|
||||
let mut points: HashSet<_> = points.into_iter().collect();
|
||||
let mut folds = folds.into_iter();
|
||||
|
||||
points = do_fold(points.into_iter(), folds.next().unwrap());
|
||||
println!("{}", points.len());
|
||||
|
||||
for fold in folds {
|
||||
points = do_fold(points.into_iter(), fold);
|
||||
}
|
||||
|
||||
for row in 0..=points.iter().map(|&(_, y)| y).max().unwrap() {
|
||||
for col in 0..=points.iter().map(|&(x, _)| x).max().unwrap() {
|
||||
if points.contains(&(col, row)) {
|
||||
print!("#");
|
||||
} else {
|
||||
print!(".");
|
||||
}
|
||||
}
|
||||
println!();
|
||||
}
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_14"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
nom = "7.1.0"
|
|
@ -1,152 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use nom::{
|
||||
bytes::complete::{tag, take_till},
|
||||
character::complete::{anychar, newline},
|
||||
combinator::recognize,
|
||||
multi::many1,
|
||||
sequence::{pair, separated_pair, terminated},
|
||||
};
|
||||
use std::collections::BTreeMap;
|
||||
use std::io::{stdin, Read};
|
||||
use std::ops::Add;
|
||||
|
||||
type Input<'a> = &'a str;
|
||||
type IResult<'a, T> = nom::IResult<Input<'a>, T>;
|
||||
|
||||
type Rule = ((char, char), char);
|
||||
|
||||
fn rule(i: Input) -> IResult<Rule> {
|
||||
separated_pair(pair(anychar, anychar), tag(" -> "), anychar)(i)
|
||||
}
|
||||
|
||||
fn parse_input(i: Input) -> IResult<(&str, Vec<Rule>)> {
|
||||
separated_pair(
|
||||
terminated(recognize(take_till(|c| c == '\n')), newline),
|
||||
newline,
|
||||
many1(terminated(rule, newline)),
|
||||
)(i)
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
struct Counter<T> {
|
||||
counts: BTreeMap<T, usize>,
|
||||
}
|
||||
|
||||
impl<T: Ord> Counter<T> {
|
||||
pub fn new() -> Self {
|
||||
Self {
|
||||
counts: BTreeMap::new(),
|
||||
}
|
||||
}
|
||||
|
||||
pub fn push(&mut self, el: T) {
|
||||
*self.counts.entry(el).or_insert(0) += 1;
|
||||
}
|
||||
|
||||
pub fn most_common(&self) -> Option<(&T, usize)> {
|
||||
self.counts
|
||||
.iter()
|
||||
.map(|(el, count)| (el, *count))
|
||||
.max_by_key(|&(_, count)| count)
|
||||
}
|
||||
|
||||
pub fn least_common(&self) -> Option<(&T, usize)> {
|
||||
self.counts
|
||||
.iter()
|
||||
.map(|(el, count)| (el, *count))
|
||||
.min_by_key(|&(_, count)| count)
|
||||
}
|
||||
}
|
||||
|
||||
impl<T: Ord> FromIterator<T> for Counter<T> {
|
||||
fn from_iter<I: IntoIterator<Item = T>>(iter: I) -> Self {
|
||||
let mut counts = Self::new();
|
||||
for el in iter {
|
||||
counts.push(el);
|
||||
}
|
||||
counts
|
||||
}
|
||||
}
|
||||
|
||||
impl<T: Ord + Copy> Add<&Counter<T>> for Counter<T> {
|
||||
type Output = Self;
|
||||
|
||||
fn add(mut self, other: &Self) -> Self {
|
||||
for (el, count) in &other.counts {
|
||||
*self.counts.entry(*el).or_insert(0) += count;
|
||||
}
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
impl<T: Ord> Add for Counter<T> {
|
||||
type Output = Self;
|
||||
|
||||
fn add(mut self, other: Self) -> Self {
|
||||
for (el, count) in other.counts {
|
||||
*self.counts.entry(el).or_insert(0) += count;
|
||||
}
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug)]
|
||||
struct LetterCounter {
|
||||
rules: BTreeMap<(char, char), char>,
|
||||
counts: BTreeMap<(char, char, usize), Counter<char>>,
|
||||
}
|
||||
|
||||
impl LetterCounter {
|
||||
pub fn new(rules: BTreeMap<(char, char), char>) -> Self {
|
||||
let mut counts = BTreeMap::new();
|
||||
for &(left, right) in rules.keys() {
|
||||
counts.insert((left, right, 0), Counter::from_iter([left]));
|
||||
}
|
||||
Self { rules, counts }
|
||||
}
|
||||
|
||||
pub fn get_counts_right_exclusive(
|
||||
&mut self,
|
||||
left: char,
|
||||
right: char,
|
||||
depth: usize,
|
||||
) -> &Counter<char> {
|
||||
#[allow(clippy::map_entry)] // lifetimes don't work out
|
||||
if !self.counts.contains_key(&(left, right, depth)) {
|
||||
let middle = self.rules[&(left, right)];
|
||||
let counts_left = self
|
||||
.get_counts_right_exclusive(left, middle, depth - 1)
|
||||
.clone();
|
||||
let counts_right = self.get_counts_right_exclusive(middle, right, depth - 1);
|
||||
let counts = counts_left + counts_right;
|
||||
self.counts.insert((left, right, depth), counts);
|
||||
}
|
||||
&self.counts[&(left, right, depth)]
|
||||
}
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let mut input = String::new();
|
||||
stdin().lock().read_to_string(&mut input).unwrap();
|
||||
|
||||
let (input, rules) = parse_input(&input).unwrap().1;
|
||||
|
||||
let rules: BTreeMap<_, _> = rules.into_iter().collect();
|
||||
let chars: Vec<_> = input.chars().collect();
|
||||
|
||||
let mut counter = LetterCounter::new(rules);
|
||||
|
||||
let mut run = |steps| {
|
||||
let mut totals = chars.windows(2).fold(Counter::new(), |counts, x| {
|
||||
counts + counter.get_counts_right_exclusive(x[0], x[1], steps)
|
||||
});
|
||||
totals.push(*chars.last().unwrap());
|
||||
|
||||
println!(
|
||||
"{:?}",
|
||||
totals.most_common().unwrap().1 - totals.least_common().unwrap().1
|
||||
);
|
||||
};
|
||||
run(10);
|
||||
run(40);
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_16"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
nom = "7.1.0"
|
|
@ -1,208 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
|
||||
use std::{
|
||||
io::{stdin, Read},
|
||||
ops::ControlFlow,
|
||||
};
|
||||
|
||||
use nom::{
|
||||
bits::complete as bits,
|
||||
error::ParseError,
|
||||
multi::{many0, many_m_n},
|
||||
Offset,
|
||||
};
|
||||
use nom::{combinator::map, sequence::pair};
|
||||
use parsers::fold_till;
|
||||
|
||||
mod parsers;
|
||||
|
||||
type Input<'a> = (&'a [u8], usize);
|
||||
type IResult<'a, T, E> = nom::IResult<Input<'a>, T, E>;
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
struct Packet {
|
||||
version: u8,
|
||||
typ: PacketType,
|
||||
}
|
||||
|
||||
impl Packet {
|
||||
pub fn parse<'a, E: ParseError<Input<'a>>>(i: Input<'a>) -> IResult<'a, Packet, E> {
|
||||
map(
|
||||
pair(bits::take(3_usize), PacketType::parse),
|
||||
|(version, typ)| Packet { version, typ },
|
||||
)(i)
|
||||
}
|
||||
|
||||
pub fn version_sum(&self) -> usize {
|
||||
usize::from(self.version)
|
||||
+ match self.typ {
|
||||
PacketType::Literal(_) => 0,
|
||||
PacketType::Operation {
|
||||
ref sub_packets, ..
|
||||
} => sub_packets.iter().map(Packet::version_sum).sum(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
enum PacketType {
|
||||
Literal(usize),
|
||||
Operation {
|
||||
operator: Operator,
|
||||
sub_packets: Vec<Packet>,
|
||||
},
|
||||
}
|
||||
|
||||
impl PacketType {
|
||||
pub fn parse<'a, E: ParseError<Input<'a>>>(i: Input<'a>) -> IResult<'a, PacketType, E> {
|
||||
let (i, operator) = map(bits::take(3_usize), |type_id: u8| {
|
||||
Operator::try_from(type_id)
|
||||
})(i)?;
|
||||
|
||||
match operator {
|
||||
Ok(operator) => map(Self::parse_sub_packets, |sub_packets| {
|
||||
PacketType::Operation {
|
||||
operator,
|
||||
sub_packets,
|
||||
}
|
||||
})(i),
|
||||
Err(_) => map(Self::parse_literal_value, PacketType::Literal)(i),
|
||||
}
|
||||
}
|
||||
|
||||
fn parse_sub_packets<'a, E: ParseError<Input<'a>>>(
|
||||
i: Input<'a>,
|
||||
) -> IResult<'a, Vec<Packet>, E> {
|
||||
enum LengthType {
|
||||
Bits(usize),
|
||||
Packets(usize),
|
||||
}
|
||||
|
||||
impl LengthType {
|
||||
pub fn parse<'a, E: ParseError<Input<'a>>>(i: Input<'a>) -> IResult<'a, Self, E> {
|
||||
let (i, length_type_id) = bits::take(1_usize)(i)?;
|
||||
match length_type_id {
|
||||
0 => map(bits::take(15_usize), LengthType::Bits)(i),
|
||||
1 => map(bits::take(11_usize), LengthType::Packets)(i),
|
||||
_ => unreachable!(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
let (i, length_type) = LengthType::parse(i)?;
|
||||
match length_type {
|
||||
LengthType::Packets(n) => many_m_n(n, n, Packet::parse)(i),
|
||||
LengthType::Bits(n) => {
|
||||
// manual implementation of something like the following:
|
||||
// map_parser(recognize(bits::take(n)), many0(Packet::parse))(i)
|
||||
|
||||
let new_byte_offset = (n + i.1) / 8;
|
||||
let new_bit_offset = (n + i.1) % 8;
|
||||
|
||||
let subpackets_input = (&i.0[..=new_byte_offset], i.1);
|
||||
let (subpackets_end, subpackets) = many0(Packet::parse)(subpackets_input)?;
|
||||
|
||||
let new_input = (&i.0[new_byte_offset..], new_bit_offset);
|
||||
assert_eq!(i.0.offset(subpackets_end.0), i.0.offset(new_input.0));
|
||||
assert_eq!(subpackets_end.1, new_input.1);
|
||||
|
||||
Ok((new_input, subpackets))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn parse_literal_value<'a, E: ParseError<Input<'a>>>(i: Input<'a>) -> IResult<'a, usize, E> {
|
||||
fold_till(
|
||||
pair(bits::take(1_usize), bits::take(4_usize)),
|
||||
|| 0,
|
||||
|acc, (marker, bits): (u8, usize)| {
|
||||
(if marker == 1 {
|
||||
ControlFlow::Continue
|
||||
} else {
|
||||
ControlFlow::Break
|
||||
})((acc << 4) | bits)
|
||||
},
|
||||
)(i)
|
||||
}
|
||||
|
||||
pub fn evaluate(&self) -> usize {
|
||||
match self {
|
||||
Self::Literal(n) => *n,
|
||||
Self::Operation {
|
||||
operator,
|
||||
sub_packets,
|
||||
} => operator.evaluate(sub_packets.iter().map(|p| p.typ.evaluate())),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
enum Operator {
|
||||
Sum,
|
||||
Product,
|
||||
Minimum,
|
||||
Maximum,
|
||||
GreaterThan,
|
||||
LessThan,
|
||||
EqualTo,
|
||||
}
|
||||
|
||||
impl Operator {
|
||||
pub fn evaluate(self, mut operands: impl Iterator<Item = usize>) -> usize {
|
||||
match self {
|
||||
Self::Sum => operands.sum(),
|
||||
Self::Product => operands.product(),
|
||||
Self::Minimum => operands.min().unwrap(),
|
||||
Self::Maximum => operands.max().unwrap(),
|
||||
Self::GreaterThan => usize::from(operands.next().unwrap() > operands.next().unwrap()),
|
||||
Self::LessThan => usize::from(operands.next().unwrap() < operands.next().unwrap()),
|
||||
Self::EqualTo => usize::from(operands.next().unwrap() == operands.next().unwrap()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl TryFrom<u8> for Operator {
|
||||
type Error = ();
|
||||
|
||||
fn try_from(value: u8) -> Result<Self, Self::Error> {
|
||||
match value {
|
||||
0 => Ok(Self::Sum),
|
||||
1 => Ok(Self::Product),
|
||||
2 => Ok(Self::Minimum),
|
||||
3 => Ok(Self::Maximum),
|
||||
5 => Ok(Self::GreaterThan),
|
||||
6 => Ok(Self::LessThan),
|
||||
7 => Ok(Self::EqualTo),
|
||||
_ => Err(()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let bytes: Vec<u8> = stdin()
|
||||
.lock()
|
||||
.bytes()
|
||||
.filter_map(|c| char::from(c.unwrap()).to_digit(16))
|
||||
.map(|c| {
|
||||
#[allow(clippy::cast_possible_truncation)] // a hex digit always fits in a u8
|
||||
let c = c as u8;
|
||||
c
|
||||
})
|
||||
.scan(None, |prev, n| {
|
||||
Some(match *prev {
|
||||
Some(i) => {
|
||||
*prev = None;
|
||||
Some(i | n)
|
||||
}
|
||||
None => prev.replace(n << 4),
|
||||
})
|
||||
})
|
||||
.flatten()
|
||||
.collect();
|
||||
|
||||
let packet = Packet::parse::<nom::error::Error<_>>((&bytes, 0))
|
||||
.unwrap()
|
||||
.1;
|
||||
println!("{}", packet.version_sum());
|
||||
println!("{}", packet.typ.evaluate());
|
||||
}
|
|
@ -1,41 +0,0 @@
|
|||
use std::ops::ControlFlow;
|
||||
|
||||
use nom::{
|
||||
error::{ErrorKind, ParseError},
|
||||
Err, InputLength, Parser,
|
||||
};
|
||||
|
||||
pub fn fold_till<I, O, E, St, P, F, G>(
|
||||
mut p: P,
|
||||
mut init: F,
|
||||
mut acc: G,
|
||||
) -> impl FnMut(I) -> nom::IResult<I, St, E>
|
||||
where
|
||||
I: InputLength,
|
||||
E: ParseError<I>,
|
||||
P: Parser<I, O, E>,
|
||||
F: FnMut() -> St,
|
||||
G: FnMut(St, O) -> ControlFlow<St, St>,
|
||||
{
|
||||
move |i| {
|
||||
let mut res = init();
|
||||
let mut input = i;
|
||||
|
||||
loop {
|
||||
let len = input.input_len();
|
||||
let (i, o) = p.parse(input)?;
|
||||
|
||||
if i.input_len() == len {
|
||||
return Err(Err::Error(E::from_error_kind(i, ErrorKind::Many0)));
|
||||
}
|
||||
|
||||
match acc(res, o) {
|
||||
ControlFlow::Continue(next) => {
|
||||
res = next;
|
||||
input = i;
|
||||
}
|
||||
ControlFlow::Break(res) => return Ok((i, res)),
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,20 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
|
||||
if __name__ == '__main__':
|
||||
x = 0
|
||||
y = 0
|
||||
z = 0
|
||||
for line in sys.stdin.readlines():
|
||||
dir, amount = line.split()
|
||||
amount = int(amount)
|
||||
if dir == 'forward':
|
||||
x += amount
|
||||
z += y * amount
|
||||
elif dir == 'down':
|
||||
y += amount
|
||||
elif dir == 'up':
|
||||
y -= amount
|
||||
print(x*y)
|
||||
print(x*z)
|
|
@ -1,9 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_22"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
nom = "7.1.0"
|
|
@ -1,167 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use std::{
|
||||
cmp::{max, min},
|
||||
io::{stdin, BufRead},
|
||||
ops::RangeInclusive,
|
||||
};
|
||||
|
||||
use nom::{
|
||||
branch::alt,
|
||||
bytes::complete::tag,
|
||||
character::complete::i64,
|
||||
combinator::map,
|
||||
error::ParseError,
|
||||
sequence::{pair, preceded, separated_pair, terminated, tuple},
|
||||
};
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
struct Cuboid {
|
||||
x: RangeInclusive<i64>,
|
||||
y: RangeInclusive<i64>,
|
||||
z: RangeInclusive<i64>,
|
||||
}
|
||||
|
||||
fn range_len(range: &RangeInclusive<i64>) -> u64 {
|
||||
(range.end() - range.start() + 1).try_into().unwrap_or(0)
|
||||
}
|
||||
|
||||
fn range_intersect(a: &RangeInclusive<i64>, b: &RangeInclusive<i64>) -> RangeInclusive<i64> {
|
||||
max(*a.start(), *b.start())..=min(*a.end(), *b.end())
|
||||
}
|
||||
|
||||
impl Cuboid {
|
||||
pub fn cubes(&self) -> u64 {
|
||||
range_len(&self.x) * range_len(&self.y) * range_len(&self.z)
|
||||
}
|
||||
|
||||
pub fn intersect(&self, other: &Cuboid) -> Option<Cuboid> {
|
||||
let x = range_intersect(&self.x, &other.x);
|
||||
let y = range_intersect(&self.y, &other.y);
|
||||
let z = range_intersect(&self.z, &other.z);
|
||||
|
||||
if x.is_empty() || y.is_empty() || z.is_empty() {
|
||||
None
|
||||
} else {
|
||||
Some(Self { x, y, z })
|
||||
}
|
||||
}
|
||||
|
||||
pub fn in_small_range(&self) -> bool {
|
||||
let check = |r: &RangeInclusive<i64>| -50 <= *r.start() && *r.end() <= 50;
|
||||
check(&self.x) && check(&self.y) && check(&self.z)
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
enum CubeState {
|
||||
Off,
|
||||
On,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, Eq)]
|
||||
struct CuboidSpec {
|
||||
state: CubeState,
|
||||
cuboid: Cuboid,
|
||||
}
|
||||
|
||||
impl CuboidSpec {
|
||||
fn parse<'input, E: ParseError<&'input str>>(
|
||||
input: &'input str,
|
||||
) -> nom::IResult<&'input str, Self, E> {
|
||||
let dimension_range = |dim| {
|
||||
map(
|
||||
preceded(
|
||||
pair(tag(dim), tag("=")),
|
||||
separated_pair(i64, tag(".."), i64),
|
||||
),
|
||||
|(start, end)| start..=end,
|
||||
)
|
||||
};
|
||||
|
||||
map(
|
||||
separated_pair(
|
||||
alt((
|
||||
map(tag("off"), |_| CubeState::Off),
|
||||
map(tag("on"), |_| CubeState::On),
|
||||
)),
|
||||
tag(" "),
|
||||
map(
|
||||
tuple((
|
||||
terminated(dimension_range("x"), tag(",")),
|
||||
terminated(dimension_range("y"), tag(",")),
|
||||
dimension_range("z"),
|
||||
)),
|
||||
|(x, y, z)| Cuboid { x, y, z },
|
||||
),
|
||||
),
|
||||
|(state, cuboid)| Self { state, cuboid },
|
||||
)(input)
|
||||
}
|
||||
}
|
||||
|
||||
fn count_intersecting(first: &Cuboid, rest: impl IntoIterator<Item = Cuboid>) -> u64 {
|
||||
let intersections = rest.into_iter().filter_map(|c| c.intersect(first));
|
||||
count_union(intersections, Entry::Use)
|
||||
}
|
||||
|
||||
enum Entry {
|
||||
Ignore(Cuboid),
|
||||
Use(Cuboid),
|
||||
}
|
||||
|
||||
fn count_union<T>(cuboids: impl IntoIterator<Item = T>, get_cuboid: impl Fn(T) -> Entry) -> u64 {
|
||||
cuboids
|
||||
.into_iter()
|
||||
.scan(Vec::new(), |previous, x| match get_cuboid(x) {
|
||||
Entry::Ignore(c) => {
|
||||
previous.push(c);
|
||||
Some(0)
|
||||
}
|
||||
Entry::Use(c) => {
|
||||
let count = c.cubes() - count_intersecting(&c, previous.iter().cloned());
|
||||
previous.push(c);
|
||||
Some(count)
|
||||
}
|
||||
})
|
||||
.sum()
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let mut small_range = None;
|
||||
let mut lit_cubes: u64 = 0;
|
||||
let mut placed_cuboids: Vec<CuboidSpec> = Vec::new();
|
||||
|
||||
for line in stdin().lock().lines() {
|
||||
let spec = CuboidSpec::parse::<()>(&line.unwrap()).unwrap().1;
|
||||
|
||||
if !spec.cuboid.in_small_range() {
|
||||
small_range.get_or_insert(lit_cubes);
|
||||
}
|
||||
|
||||
// all overlaps with previous cuboids
|
||||
let intersections = placed_cuboids.iter().cloned().filter_map(|mut s| {
|
||||
s.cuboid = s.cuboid.intersect(&spec.cuboid)?;
|
||||
Some(s)
|
||||
});
|
||||
|
||||
// count the cubes that overlap with currently-ON cubes
|
||||
let overlap = count_union(intersections.rev(), |s| {
|
||||
(if s.state == CubeState::On {
|
||||
Entry::Use
|
||||
} else {
|
||||
Entry::Ignore
|
||||
})(s.cuboid)
|
||||
});
|
||||
|
||||
if let CubeState::On = spec.state {
|
||||
let size = spec.cuboid.cubes();
|
||||
lit_cubes += size;
|
||||
};
|
||||
lit_cubes -= overlap;
|
||||
|
||||
placed_cuboids.push(spec);
|
||||
}
|
||||
|
||||
println!("{}", small_range.unwrap());
|
||||
println!("{lit_cubes}");
|
||||
}
|
|
@ -1,38 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
from collections import Counter
|
||||
|
||||
def most_common(ns, pos):
|
||||
c = Counter(n[pos] for n in ns)
|
||||
num_zeros = c['0']
|
||||
num_ones = c['1']
|
||||
if num_ones >= num_zeros:
|
||||
return '1'
|
||||
else:
|
||||
return '0'
|
||||
|
||||
def least_common(ns, pos):
|
||||
return '0' if most_common(ns, pos) == '1' else '1'
|
||||
|
||||
def find_criteria(ns, criteria):
|
||||
ns = ns
|
||||
i = 0
|
||||
while len(ns) > 1:
|
||||
x = criteria(ns, i)
|
||||
ns = [n for n in ns if n[i] == x]
|
||||
i += 1
|
||||
return ns[0]
|
||||
|
||||
if __name__ == '__main__':
|
||||
lines = [line.strip() for line in sys.stdin.readlines()]
|
||||
|
||||
line_len = len(lines[0])
|
||||
gamma = ''.join(most_common(lines, n) for n in range(line_len))
|
||||
epsilon = ''.join(least_common(lines, n) for n in range(line_len))
|
||||
print(int(gamma, 2) * int(epsilon, 2))
|
||||
|
||||
oxygen_rating = find_criteria(lines, most_common)
|
||||
co2_rating = find_criteria(lines, least_common)
|
||||
|
||||
print(int(oxygen_rating, 2) * int(co2_rating, 2))
|
|
@ -1,8 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_3"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
|
@ -1,58 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use std::io::{stdin, BufRead};
|
||||
|
||||
fn find_rating(num_bits: usize, mut range: &[usize], keep_most_common_bit: bool) -> usize {
|
||||
for idx in (0..num_bits).rev() {
|
||||
if range.len() == 1 {
|
||||
break;
|
||||
}
|
||||
|
||||
let nth_bit = |x| x >> idx & 1;
|
||||
let partition_point = range.iter().position(|&n| nth_bit(n) == 1).unwrap();
|
||||
let center_bit = nth_bit(range[range.len() / 2]);
|
||||
|
||||
let keep_first_half = if keep_most_common_bit {
|
||||
center_bit == 0
|
||||
} else {
|
||||
center_bit == 1
|
||||
};
|
||||
|
||||
if keep_first_half {
|
||||
range = &range[..partition_point];
|
||||
} else {
|
||||
range = &range[partition_point..];
|
||||
}
|
||||
}
|
||||
|
||||
range[0]
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let lines: Vec<_> = stdin().lock().lines().map(Result::unwrap).collect();
|
||||
|
||||
let num_bits = lines[0].len();
|
||||
|
||||
let gamma: usize = (0..num_bits)
|
||||
.map(|i| {
|
||||
lines
|
||||
.iter()
|
||||
.filter(|line| line.chars().nth(i).unwrap() == '1')
|
||||
.count()
|
||||
})
|
||||
.map(|n| if n > lines.len() / 2 { 1 } else { 0 })
|
||||
.reduce(|accum, bit| accum << 1 | bit)
|
||||
.unwrap();
|
||||
let sigma = !gamma & ((1 << num_bits) - 1);
|
||||
|
||||
println!("{}", gamma * sigma);
|
||||
|
||||
let mut numbers: Vec<_> = lines
|
||||
.iter()
|
||||
.map(|n| usize::from_str_radix(n, 2).unwrap())
|
||||
.collect();
|
||||
numbers.sort_unstable();
|
||||
|
||||
let oxygen = find_rating(num_bits, &numbers, true);
|
||||
let co2 = find_rating(num_bits, &numbers, false);
|
||||
println!("{}", oxygen * co2);
|
||||
}
|
|
@ -1,41 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import time
|
||||
|
||||
import sys
|
||||
|
||||
def board_won(board):
|
||||
for row in board:
|
||||
if all(x is None for x in row):
|
||||
return True
|
||||
for i in range(len(board[0])):
|
||||
if all(row[i] is None for row in board):
|
||||
return True
|
||||
return False
|
||||
|
||||
if __name__ == '__main__':
|
||||
lines = [line.strip() for line in sys.stdin.readlines()]
|
||||
|
||||
draws = [int(n) for n in lines[0].split(',')]
|
||||
|
||||
boards = []
|
||||
for i in range(2, len(lines), 6):
|
||||
boards.append([[int(n) for n in line.split()] for line in lines[i:i+5]])
|
||||
|
||||
wins = []
|
||||
for draw in draws:
|
||||
for board_idx, board in enumerate(boards):
|
||||
if board is None:
|
||||
continue
|
||||
for row in board:
|
||||
try:
|
||||
idx = row.index(draw)
|
||||
row[idx] = None
|
||||
except ValueError:
|
||||
pass
|
||||
if board_won(board):
|
||||
wins.append(draw * sum(n for row in board for n in row if n is not None))
|
||||
boards[board_idx] = None
|
||||
|
||||
print(wins[0])
|
||||
print(wins[-1])
|
|
@ -1,9 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_5"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
vector2d = "2.2.0"
|
|
@ -1,114 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use std::{
|
||||
convert::Infallible,
|
||||
io::{stdin, BufRead},
|
||||
str::FromStr,
|
||||
};
|
||||
use vector2d::Vector2D;
|
||||
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
struct Line {
|
||||
start: Vector2D<usize>,
|
||||
end: Vector2D<usize>,
|
||||
}
|
||||
|
||||
impl Line {
|
||||
pub fn is_straight(&self) -> bool {
|
||||
self.start.x == self.end.x || self.start.y == self.end.y
|
||||
}
|
||||
|
||||
pub fn expand(&self) -> impl Iterator<Item = Vector2D<usize>> {
|
||||
LinePoints::new(self)
|
||||
}
|
||||
}
|
||||
|
||||
impl FromStr for Line {
|
||||
type Err = Infallible;
|
||||
|
||||
fn from_str(s: &str) -> Result<Self, Self::Err> {
|
||||
let parts: Vec<_> = s.split(' ').collect();
|
||||
let start: Vec<_> = parts[0].split(',').map(|n| n.parse().unwrap()).collect();
|
||||
let end: Vec<_> = parts[2].split(',').map(|n| n.parse().unwrap()).collect();
|
||||
|
||||
Ok(Line {
|
||||
start: Vector2D::new(start[0], start[1]),
|
||||
end: Vector2D::new(end[0], end[1]),
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
struct LinePoints {
|
||||
pos: Vector2D<isize>,
|
||||
step: Vector2D<isize>,
|
||||
points_left: usize,
|
||||
}
|
||||
|
||||
impl LinePoints {
|
||||
fn new(line: &Line) -> Self {
|
||||
let start = line.start.as_isizes();
|
||||
let end = line.end.as_isizes();
|
||||
let delta = end - start;
|
||||
let step = Vector2D::new(delta.x.signum(), delta.y.signum());
|
||||
|
||||
let len = usize::max(delta.x.unsigned_abs(), delta.y.unsigned_abs());
|
||||
|
||||
Self {
|
||||
pos: start,
|
||||
step,
|
||||
points_left: len + 1,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Iterator for LinePoints {
|
||||
type Item = Vector2D<usize>;
|
||||
|
||||
fn next(&mut self) -> Option<Self::Item> {
|
||||
if self.points_left == 0 {
|
||||
return None;
|
||||
}
|
||||
|
||||
let current = self.pos;
|
||||
self.pos += self.step;
|
||||
self.points_left -= 1;
|
||||
Some(current.as_usizes())
|
||||
}
|
||||
}
|
||||
|
||||
fn count_overlaps<'a>(it: impl IntoIterator<Item = &'a Line>) -> usize {
|
||||
let points: Vec<(usize, usize)> = it
|
||||
.into_iter()
|
||||
.flat_map(Line::expand)
|
||||
.map(Into::into)
|
||||
.collect();
|
||||
|
||||
let (max_x, max_y) = points.iter().fold((0, 0), |(acc_x, acc_y), &(x, y)| {
|
||||
(usize::max(acc_x, x), usize::max(acc_y, y))
|
||||
});
|
||||
|
||||
let mut field = vec![vec![0_usize; max_y + 1]; max_x + 1];
|
||||
|
||||
let mut hits = 0;
|
||||
for (x, y) in points {
|
||||
let point = &mut field[x][y];
|
||||
if *point == 1 {
|
||||
hits += 1;
|
||||
}
|
||||
*point += 1;
|
||||
}
|
||||
hits
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let lines: Vec<Line> = stdin()
|
||||
.lock()
|
||||
.lines()
|
||||
.map(|s| s.unwrap().parse().unwrap())
|
||||
.collect();
|
||||
|
||||
println!(
|
||||
"{}",
|
||||
count_overlaps(lines.iter().filter(|line| line.is_straight()))
|
||||
);
|
||||
println!("{}", count_overlaps(&lines));
|
||||
}
|
|
@ -1,20 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
import functools
|
||||
|
||||
@functools.cache
|
||||
def spawns(days):
|
||||
acc = days//7
|
||||
days -= 9
|
||||
acc += sum(spawns(days-x*7) for x in range(days//7))
|
||||
return acc
|
||||
|
||||
if __name__ == '__main__':
|
||||
inp = [int(i) for i in sys.stdin.readline().split(',')]
|
||||
|
||||
def do(days):
|
||||
spawns.cache_clear()
|
||||
return sum(1 + spawns(days + (6 - fish)) for fish in inp)
|
||||
print(do(80))
|
||||
print(do(256))
|
|
@ -1,15 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
|
||||
if __name__ == '__main__':
|
||||
positions = [int(i) for i in sys.stdin.readline().split(',')]
|
||||
|
||||
def calc(movement_cost):
|
||||
return min(
|
||||
sum(movement_cost(abs(position-target)) for position in positions)
|
||||
for target in range(min(positions), max(positions)+1)
|
||||
)
|
||||
|
||||
print(calc(lambda n: n))
|
||||
print(calc(lambda n: n * (n+1)//2))
|
|
@ -1,30 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
|
||||
if __name__ == '__main__':
|
||||
positions = [int(i) for i in sys.stdin.readline().split(',')]
|
||||
|
||||
def calc(starting_guess, distance_cost):
|
||||
def target_cost(target):
|
||||
return sum(distance_cost(abs(position-target)) for position in positions)
|
||||
|
||||
target = starting_guess(positions)
|
||||
current_cost = target_cost(target)
|
||||
|
||||
for i in (-1, 1):
|
||||
while (next_cost := target_cost(target+i)) < current_cost:
|
||||
current_cost = next_cost
|
||||
target += i
|
||||
|
||||
return current_cost
|
||||
|
||||
positions.sort()
|
||||
print(calc(
|
||||
lambda positions: positions[len(positions)//2],
|
||||
lambda n: n
|
||||
))
|
||||
print(calc(
|
||||
lambda positions: int(sum(positions)/len(positions)),
|
||||
lambda n: n * (n+1)//2
|
||||
))
|
|
@ -1,46 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
import itertools
|
||||
|
||||
def parse(line):
|
||||
inputs, outputs = [[num.strip() for num in nums.strip().split(' ')] for nums in line.split('|')]
|
||||
return (inputs, outputs)
|
||||
|
||||
if __name__ == '__main__':
|
||||
inp = [parse(i) for i in sys.stdin.readlines()]
|
||||
|
||||
permutations = list(''.join(s) for s in itertools.permutations('abcdefg'))
|
||||
segments = [
|
||||
'abcefg',
|
||||
'cf',
|
||||
'acdeg',
|
||||
'acdfg',
|
||||
'bcdf',
|
||||
'abdfg',
|
||||
'abdefg',
|
||||
'acf',
|
||||
'abcdefg',
|
||||
'abcdfg',
|
||||
]
|
||||
|
||||
acc1 = 0
|
||||
acc2 = 0
|
||||
for (inputs, outputs) in inp:
|
||||
acc1 += sum(len(output) in (2,3,4,7) for output in outputs)
|
||||
|
||||
for permutation in permutations:
|
||||
trans = str.maketrans(permutation, 'abcdefg')
|
||||
|
||||
def translate_segments(digit):
|
||||
return ''.join(sorted(digit.translate(trans)))
|
||||
|
||||
if all(translate_segments(digit) in segments for digit in inputs):
|
||||
acc2 += int(''.join(
|
||||
str(segments.index(
|
||||
translate_segments(digit)
|
||||
)) for digit in outputs
|
||||
))
|
||||
break
|
||||
print(acc1)
|
||||
print(acc2)
|
|
@ -1,16 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
from collections import Counter
|
||||
|
||||
if __name__ == '__main__':
|
||||
acc1 = 0
|
||||
acc2 = 0
|
||||
for line in sys.stdin.readlines():
|
||||
inputs, outputs = line.split('|')
|
||||
counter = Counter(c for cs in inputs for c in cs)
|
||||
digits = [{17: 1, 25: 7, 30: 4, 34: 2, 37: 5, 39: 3, 41: 6, 42: 0, 49: 8, 45: 9}[sum(counter[c] for c in output)] for output in outputs.strip().split()]
|
||||
acc1 += sum(digit in (1, 4, 7, 8) for digit in digits)
|
||||
acc2 += int(''.join(str(digit) for digit in digits))
|
||||
print(acc1)
|
||||
print(acc2)
|
|
@ -1,16 +0,0 @@
|
|||
[package]
|
||||
name = "rust_2021_8"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[dependencies]
|
||||
arrayvec = "0.7.2"
|
||||
|
||||
[dev-dependencies]
|
||||
criterion = "0.3.5"
|
||||
|
||||
[[bench]]
|
||||
name = "unscramble"
|
||||
harness = false
|
|
@ -1,40 +0,0 @@
|
|||
use std::{fs, path::PathBuf};
|
||||
|
||||
use criterion::{black_box, criterion_group, criterion_main, Criterion};
|
||||
use rust_2021_8::{v1, v2, v3};
|
||||
|
||||
pub fn criterion_benchmark(c: &mut Criterion) {
|
||||
let mut group = c.benchmark_group("unscramble");
|
||||
|
||||
let mut data_file = PathBuf::from(env!("CARGO_MANIFEST_DIR"));
|
||||
data_file.push("inputs/input.txt");
|
||||
|
||||
let input = fs::read_to_string(data_file).unwrap();
|
||||
let lines: Vec<&str> = input.lines().collect();
|
||||
|
||||
group.bench_function("v1", |b| {
|
||||
b.iter(|| {
|
||||
for line in &lines {
|
||||
let _ = v1::unscramble(black_box(line));
|
||||
}
|
||||
})
|
||||
});
|
||||
group.bench_function("v2", |b| {
|
||||
b.iter(|| {
|
||||
for line in &lines {
|
||||
let _ = v2::unscramble(black_box(line));
|
||||
}
|
||||
})
|
||||
});
|
||||
group.bench_function("v3", |b| {
|
||||
b.iter(|| {
|
||||
for line in &lines {
|
||||
let _ = v3::unscramble(black_box(line));
|
||||
}
|
||||
})
|
||||
});
|
||||
group.finish();
|
||||
}
|
||||
|
||||
criterion_group!(benches, criterion_benchmark);
|
||||
criterion_main!(benches);
|
|
@ -1,200 +0,0 @@
|
|||
bgafcde gfcd agc ebdgac adfceb bafeg efgca cgdfae cg ecadf | fabgced gc agc cdfg
|
||||
gbdacfe gcabfd cdb dcfba bfacg cgad fadeb feabcg cd gcbfed | bdagcef dcb cdag gbfca
|
||||
dgcbafe dbfca fbaed be cedb gefad dcfeab facdgb eba gbface | eb gadfcbe cfbad gfbeca
|
||||
ebc cb aedbf agcef badecg gaebfc bcgf adbcfge ceabf daecgf | cb bce efdab ecbaf
|
||||
fedbc cebad gfcbd fec gcdfab ecbfga dacgbfe gfed fe gefbdc | bfecag cef egdf fgde
|
||||
bafedc baefg dbfga daegcb gae egbcfa eg cefab fgce decbafg | abdgf cgfe cedgba befga
|
||||
dcba fagbed cgbfed dgfbeac da dag acbgde fcaeg becgd acgde | agd bacd dga gbecad
|
||||
ec aebgcfd fecd bagfec efagd edfgab cgdfea dgcab ecdga eac | ce ec ce gbacefd
|
||||
aegdbfc fe dacbf aefbgd aecgb cdfe ebadcf ecbfa cbfdga aef | dfce fe fcde afebdgc
|
||||
bgaf gcbad cagdfb gb dfbeca degfcb bfadc cfgeadb bdg agcde | fdegacb acbefgd bdg gafb
|
||||
gdecba dcae ec dbfeag bgead dgbce gec cgefab dcbgefa cdbfg | afdbgce agbfde abcgefd ec
|
||||
gacbefd fgbedc egafdc adf fcbae afedb ad bfeadg adbg dfgeb | ad degcfa ad dfbge
|
||||
fadebc baef eadfcg ebgdc eda cfgabd afbdc ea edcab cdgbefa | aefb ead ea ebaf
|
||||
badgecf caefd aebfdc fecbdg fadcg fed de ebad abgecf bceaf | ed gcfebd aebd gfdca
|
||||
bcdae aefcbg fgdea bf cdabegf adcebf fcbd fbead afb begadc | gbcafe faegbc fba eabdc
|
||||
bfcdeg ecd eabgc adeg ed dbaec bcfad ecabfg dbgcfea dbacge | de bdfcaeg ecgfbd bcdea
|
||||
deacf bf eagfdb gfecadb facbeg bfa cbdage abfce fbcg gecab | aebcf ecfagb abegfd bgeac
|
||||
eag dgbecf gdfae caed dfebgca ea ebcgfa dfbag gecfda dgcfe | ae ea deac fcdega
|
||||
edbga egdabc cgfdbe gabfe efcdgab gbdefa fb abdf fbg gecfa | cgaebd cbgdea acgfe begdca
|
||||
cgfedb egbdc agcfd cdagb eabgdf ab abce adb agcebfd dabegc | ba bda abd deagfb
|
||||
fc agfbce fdebg dgafeb ebfdc cbf cfedgba fdcg gcefdb eacdb | gbfaec fgcbed gbceafd bedagf
|
||||
bdcgefa acdfbe ed gbcea cfgbad ecbda edfcag afcbd ead bdef | dfbe de dea dea
|
||||
gfbeca gcefdb fegacd cgbda fbde ed bgedc begcf agdcefb ced | gbacd ced dec bcegfd
|
||||
dgbacf gfabec agd egdaf badcegf ad ecgaf defgb cade dfegca | cdae dga bgcaef ad
|
||||
dcf cfadb bcagd afebd fbgdec egfcbda fcea gfeabd fc ebdfac | gabdc ebfad aefc eacbdf
|
||||
cfgdba fcdab cgfbade adeb afdebc egcfdb de aedfc cfage edf | ed eadb dgebcf cefdabg
|
||||
bcae befga dgebfc fbagce cbefg agb fcedgab ba bdgacf dgfae | beca dcaegbf gab geafb
|
||||
dgafbec fedba cbega aebfdc eabfdg bdgfce edc fdac cd adceb | abedf dfeabg dc gdbefc
|
||||
adegfbc gbedcf cfabd gacedb abcfe fdbacg dgabc df dfga bfd | fdag dbf dafg fd
|
||||
dfbcag ebfcad ed agecdb bfacd egbfa badfe afbcegd aed cdef | afebd ecdf cfed eadfbgc
|
||||
fca dbcaf ebdcf fadbg cdbefa adec ac dacbgfe fbcdge cgefba | ac edca edac ca
|
||||
agdfce cedbfag agc dcbaeg gc bcdga bgdfa cfaebd ebdac cbge | ceadb becg ebadc gc
|
||||
aefbc aecdg efgcad cdebag bcg agfdbc bceag bdge bg fecdgab | bgecda bcdaeg gb caebf
|
||||
cfgebd acedf ag gbad gcfbad acg bgecfa bdfcg gbadecf cdfga | dgba dgcbf gac bgfdc
|
||||
cdgbafe cdgbe gd agde bcaged dfebc geacb cdg bgeacf gbdcfa | efgcba edag gecfdba cgd
|
||||
bcg bcaf cegdaf dfacg dgacb fgcebda bgdcaf efbcgd bc gadbe | gcb bcg caebdfg cfab
|
||||
eg cdgfae aecfd fgbaedc gbdfc facdeb cfegd ceag efg efdgab | fge acefbgd egf efg
|
||||
fcdg gefda cf edabc cedgfa cfa acefd cfebadg gdbafe bgecfa | fc fca cfabged fca
|
||||
ed bcadegf egdfb fgcdb edbafg facbeg abegf deba fadgec dge | eadb ged eadb adfegb
|
||||
bgedc cf cefadg ecbgdf gbfae cbdf fcg ecbgad abfgced becfg | bdcf dbceg fgcbde cdbeg
|
||||
cg gcaf defcag cdefg gdafe dgfabe gec dabegfc bcegad ebdcf | feadg degcf gcaf dcgefa
|
||||
fdeac gdcebf daecbg bgfec fdeagbc gca gecfa aefcbg fbag ag | ga decfagb ag agfb
|
||||
bc fbdc bagecdf gfdcab acdgb dcaeg dbgfa cgbaef ebgfda gbc | bdfc cb cfbd fbcd
|
||||
efagc bafegd abecg eab eb fgbeca gbedcfa bfec fcgade cgbad | abfgdce degacf fcaebg cdabfeg
|
||||
egbfcd afde ecgab fac fa edabcf cbdagfe afbec cfabgd fdebc | deaf feda cgbdfa fa
|
||||
gbafd defca ebcf eb cefbad dcebag dcgfae edfab deb bgedcfa | be deb gdbafce be
|
||||
afdgceb cf gbdeaf acdbfe abcef acf deafb fedgac cdbf cgeba | fac cfdb bdfcae fdcb
|
||||
cfdba ca afbgd eabc cda afbcdeg cfedb ecfgbd efcgad bcfeda | bfgad abec abce caeb
|
||||
cfebad debfacg acgfeb cab fedcb afcdb cdae febcdg ac dgbaf | bac ca faecbgd cgbfae
|
||||
eg dfcegb dge abedcgf facdg bafdgc degacf dafeg agec adebf | egd fegda fedbcag eagdf
|
||||
age gcbad feacb cgbdfae ge gfbe agebc fcadeg cbafde cgebaf | fagecdb bfeg baecg fceabd
|
||||
bfcdge fgcbead ebdgac ba dagbfe gab dabc bcegd gface cebga | cbda gbedc egcbafd gab
|
||||
dbcegfa fadceg fcage bcage gb bdagfc abdec gbfe bgafce bcg | ebfdagc ebfg ebgf egfb
|
||||
gcdefa bagf dgebf bdefc bgcafde dbefga edabg gfe gf dcgeba | fg efg agfb gebfd
|
||||
fabdc gdeabf dag gbace adcgb gd eagfcb gaedbc egdfabc egdc | adgbc bcadf gd cedfabg
|
||||
deagcf ce dfcaeb gfadceb bgade cde daegc cgdafb gadcf efcg | dbaecf fdecbga ce ecd
|
||||
dfcbag abceg db dgcefa dabec bcegdaf cdb bdef defac cfbdea | gdafec dcb febd bdef
|
||||
ead fgceabd edgcaf da fgda fgcea ecdgb cgaed fdbace cbagef | ad eafcdb bfecagd ad
|
||||
ab caefg agbcef efacb gecdfba ecfagd fbdec bdecga cba fgab | eafgc abfg cdagbfe dcageb
|
||||
afbcge ebafcgd dacegb cfbea afbg agc egcfa ag cgdfe bdceaf | adfbceg fagb gfba aecgbf
|
||||
acg cdegbf ecfadg cgdab fcbadg cdbgfae ca agedb cbgdf facb | cdeabfg ca afbc dagfec
|
||||
dca dbfae bagdcf aceg ac afdegc cegfd fcedgb cbdaegf cedfa | dac acge cedgf cfdbgae
|
||||
gdcafe ega cgbfde cgba afdbe bacegd ga begdc dcebagf edgab | abgc ga bacg bdacge
|
||||
begfda gdafce fg gdbf gbaced agf decagbf aebdg gabfe cebfa | fag acdbeg agcdfe dgbefca
|
||||
gfcdbea fecab cbadge afgce gc fgdace fdcg cga eagdf eagbfd | efgacbd gc dgfc dacbeg
|
||||
gdbefc feadg dbagef afd abde gebfd cefga bdgafc da efdacbg | cbegfda adf bade cdgfbe
|
||||
aefbdgc eabcfg cgefa degbf cedfg cd cadg cde fgecad fecadb | dbfegca egcdabf gcda dc
|
||||
baed bcgda abdegc decag ega dgbfaec gacbfe ae cgfde dbacgf | aebd age ea bgdecfa
|
||||
abecg faegcd egfcd efcga cdaf baedgf efa fcbaedg fcgedb fa | afe af aef fa
|
||||
abgfce cbedgaf fbedc eacdfb dcf fd faegcd fecba dfba gdceb | faecdg gdceb dfc gcbde
|
||||
fgce fgadb egdabc edg defbg eg bfced fdbace bdfgeac gbcfde | gdcbfea deg afbedc dgcaeb
|
||||
eg dgcfe efdgab bfdec aecg acbegfd bdcafg adcfg efg daefgc | fge aecg gfe ecagfdb
|
||||
acdfe bedcfg abgec cfeabd aedbfcg fecdag fg fcg afecg gdaf | cdaefg fdag cgf gadcfbe
|
||||
aedc gbdac cbagfe bfdcg gdbfea acb cbgaed ac eadgb gecadfb | gbfdc gbdaec fbgeadc decabg
|
||||
gbc afgdb cfbdga badgef gadbce egabcdf geacf bcdf cb gabfc | fgaec fcagdeb gbcfa bc
|
||||
cfgabd cfdbe eafgdc badcfeg dgfab cbag eafbdg gc dfgbc cdg | fagecd cgd afdbge cg
|
||||
eadcbf fcag gc gbc gadcefb gebad febdgc egcbaf ecbag bacef | dgbfec egadcbf gcfa bcegfda
|
||||
acbeg acgedb eg dgbfce cdagb cgdbaf gaed bafce cfebadg ecg | dbgac eabcf eabfdgc eagd
|
||||
bgefda eacg abdcfe eabcd abegcd ebg cbedg cbfdg dgfecab eg | ecag eg ge afebcd
|
||||
dgecbf bg dfcba abge gadebc edagc bcg ecdfga fbgecad bgcad | cgb gbea ebgcdf gbae
|
||||
dcabg gdfbca debc aed ed fabeg afdecg gbeda caegbd agbfcde | fcbdgea cedb dea efcdagb
|
||||
edbcafg cgaed gc gbdc acfebd cge gceabd abecd afegd bgafce | gc facegbd edbcaf cg
|
||||
gadbce gbdaf acebgf bd abcgfd edfga cdfb gbd cfgab dgafbce | gfdab fdegbac eabcfdg bgcdae
|
||||
eacgf fb cegbdf dgbfca cfb dfba agfcb cgabd ebcdgfa gedacb | acbdg dbaf ceafg bf
|
||||
gebac egdacf fdceg daef af gfa dagfbc fcgbead afgce cebfgd | afg bcage gcdeabf cgfea
|
||||
cdabfg fgbec gcdafe ceafgb egc ec beac febdg bdegcfa fabcg | cafegdb beca ecgbfa bace
|
||||
gda feabdg ebgaf bgdfc bgfcae bfeagdc edab ad adgbf fceagd | gad ad afgbde dfaebg
|
||||
bfc bgfced edbfag fcea cf afgbdce cgbda abgef fcgba aebcfg | bcf efac eacf fc
|
||||
bdeag bgdcf ec ebgdfac gcbde gaec dec cafdeb afdebg cebdag | gcbfd agedb acfdbe ecd
|
||||
befad gd edgbf bcgafd cebgfd abgcef gfd ecgd cgdfaeb ecfgb | cegd cdeg efadbgc egcdbaf
|
||||
gfdbae bc cegbfd gadcf cdaefgb gfbed fbcgd beagcd gbc becf | gedcfba edcagb fbcgdae cfbe
|
||||
ecf cbdaf bdfcaeg fagdec efba bcdfe bfecda gcedb ef cbadgf | ef fbedc dbceg edgfcab
|
||||
cabde ae ecfdba cbdfe faed dabcg cfbgaed gbfcea begdcf abe | adfe aeb cabgd ae
|
||||
gefcabd ecabd gebafc ag ecfgbd gacdbf dfcbg fdga cagbd acg | gebcadf gefbac dgaf dagf
|
||||
bgde efcgd cebgfa dbacgf cgfeb gdc fdaec dfbceg gd fegcadb | efbcadg cgd gbdcfa facebg
|
||||
gefcbd bgfdcea fg dcbag fbgcd fgeb defcag fcg becfad dfcbe | cefbda cfg fegbdc fg
|
||||
bcfed bcfdge aedbfg fad decbfa facge cdba efdca ad dbfagce | eabfgd fadce begfdca gecdbaf
|
||||
edfgbca dbega fdb gfecab fd ebcfda cfda feabd becfa edgbfc | df ebgad cabegfd adcf
|
||||
daegbc fbacg edfg befdac efbcd edafbgc cdg bcgfd fdegcb gd | dg becdf dbeafcg gadefcb
|
||||
egdacf gde ed dfebcag acgdfb cfadg agebdf cgeab gecda dfce | fedagc gabfecd eadgfbc cfgebda
|
||||
dfcea afbde fdgac gefbac eabcdf ace bced ec ebagfd adgbcfe | ce fcdga baecfg cea
|
||||
adebg gdfcae gb acegd abg begc bdaef bfgcda dgaefbc abgdec | bg cbafgd ecbg gba
|
||||
bfacde egfadcb cb fcdea eacbf cedb dcgeaf bgadfc abc ebgfa | adfebc dceb bdcafe efdac
|
||||
faegbd dgfce dcgafe fgadecb bcgd bcfge bfaec gb cdbfeg fgb | aecfb fbg fcgade dafgbec
|
||||
fgacbe fc ebcadg agfdb fdbca cagbdfe cdfe abcde fcb bfacde | cabed cfde bfdac dgbaf
|
||||
defabc gfcbe fea bdacfg adgecf fabce ae aebd bfecdga cdafb | fea ea bgfaced bead
|
||||
dfgae dcafe dce dgebfca abfcd ecab bfcdea gcfebd gafcbd ec | bcdagf cde gbedcfa bfdace
|
||||
cea gaedfb acdf ac ebacgd gefdabc befda cfbae egcfb efcabd | gcaebfd cbaef dfac ca
|
||||
gebac befadgc bedcgf cgb gc eagbdc cebaf cadg bgfaed aegdb | cbg cbg cbgadef acdg
|
||||
gfcdeb bfdegca beac befda bcf dcfga fbcda cb adecfb gbefda | fbc dbafc cbf cfb
|
||||
cbdfeag becagf acgeb be cgbda gfcdbe efba acfeg ecb eadgcf | aebf eb bagcfe eb
|
||||
febg aecbdg fedacb ecg ge fbgaedc dfgce afcgd fcbed efcdgb | aedcbg baegcfd ecg bedcf
|
||||
bcfedg gdbcae febd fcbag fgbcd bd ecdgfa dbc fdcagbe gdcfe | efgbadc fcbedg abfecgd cgbedf
|
||||
feagc cb dcgeabf fadbgc cgfdae fbdea feagcb bcafe cbeg bac | bgce bc cgadbf cba
|
||||
efagbd dageb dcgbeaf gc acg gdecab gecd fdbca gbcfea acbgd | eagbd egfabcd gfbace gca
|
||||
ae cgae dea eacgfd fadgc gfebd afdcbe dfeag acbfgd dacbgef | dgbafc cbdfgae ae ead
|
||||
egb gcfe abcfdeg begfcd abcdfg dabec eg bdfcg edgcb bedagf | bdecg beg gbdcef dbeac
|
||||
fcgae dfcebag aefdb geacbf cda dagbcf cd adcfe fedacg gdce | bcdafg adefb fdeba gecbfa
|
||||
afegd gadfb fcgadeb gbcade gdabef cefgad dfbe bdg fagbc bd | dabegc bfgca bd dgb
|
||||
dfceba faecd bd afbedgc ebad fcadb bafgc dcb efgdcb gfaedc | faedc bead egcdbaf bd
|
||||
cgb bdcfeg cg gdbeca cgef gdbcfea febdg fdcgb dafgeb bacfd | cgfe cgb gc gfec
|
||||
cadgfb cefdbag cg begacf dfgbea bgc adgbf bgcad fdgc eabcd | cg fgceab ebdacgf ecbdgaf
|
||||
bgdefc decfg cfedga cefgb bfdcea edgfacb bgcd fegba ceb cb | cfgbe dcaefg cbgfe dbcg
|
||||
gefbda acde gcbaf cd cfd bdcgfae daefg gdcbfe cgefad agdcf | gcebafd efgcda cfd aecd
|
||||
gedfc cead egbfda fgcdabe de fcgea gfdbc deg cagdef gebacf | deg bfgead gdfbc gde
|
||||
fbgae bfecg dbcaef gdcaeb cbfdge gbc decgbfa edbfc fdgc gc | gc gbcdef fdcg gfcbe
|
||||
fc caf cadbe dgabfc gebdfa fecg fagbe cebaf acbegdf cgabfe | egcf ceagbf gcfe ebgafc
|
||||
abfcd cgbfa bcgafd gadefc abfde cdf dc agfbced cbegfa gcbd | cd cfd fgeacd cdf
|
||||
bdgae gfbce cbagfd gedbcaf ebcgd gbcefa dc fcde cegdfb dbc | dcegb fgdcbea deabcfg bdc
|
||||
ebcagf df bgcdefa fdceba cgdf dbacgf eadbg afd abgcf gabfd | ceagdbf dagcbf fd dcfbaeg
|
||||
dga cadbgef efbcgd bgdca eacd cedbga gdbec gdeabf fbacg da | dag adg edac edgcb
|
||||
febcg gbadce aedbcf acbed cbgae cag gadb degbcfa ga fcgdae | bgad abdgfec acbed acg
|
||||
gdcaf dcbfag gdefa abcdg bcfg cf fedgacb dbaegc fcedba afc | cf afc gcfb eafdgbc
|
||||
gdcaef gcabfd bcefgda cde gcdfb gbecfd ec dfaeb cefbd egbc | egbfdc ce gbdcfa afbcgd
|
||||
fdea fga fa adcgbef abfcge gbeda fagdb abedgc cgbdf bdefag | fa gaecfb beadgc cbfgd
|
||||
ba gcbafd decgba bfga fbadc bda dfbeacg ecfgbd cedfa fdbgc | gfab gbdfc adb ba
|
||||
bd ecdgab aedfg bde fbcae decfba cgafbe fdeab dbfc fdgceba | db dbe cdfb bdgfaec
|
||||
bd gcefbd ebcd dafbgc ebfgd decgaf edcfg fbd fbaeg gafcdbe | cbeagdf cebd cedb cedb
|
||||
edagf cdaefbg ead efgdb bgafed cfdag bfea dabgce dfbceg ae | gcafd feab dgfca feba
|
||||
gecfda bgcdf ba abd edgabf bcdeaf gedfa fdbga baeg abegcdf | ab bad bda fgebcda
|
||||
egadb bec dbefga cbafg cageb ce ebdgca dceg gdebfca cfbead | ec ebc egdc ecb
|
||||
cbgfe fadcbg agde cbdge egdacb degcabf bed faebdc ed dcabg | eadg facdbe bcdeg debfac
|
||||
fabe fb bgf edcgaf bgacd bcfegd fcdegab adgef afbdg gbfade | bfg dbcgfae edacbgf bf
|
||||
bcdfe becgd cbafegd decag geb dgfb bfcade dgcefb bg gfbaec | bdgce gb dcbge gdfb
|
||||
egcadf bfg fgbdac faedg ebaf gcedb begdf fb adfebg cafdgeb | faedbcg bafcgde bf becgd
|
||||
edafgb ecbgd gcdfaeb ef gbfadc cgfade gef fdegc fgcda efca | agfecdb dcabgef ef dgcaf
|
||||
cbdgea fegcad bagdc abdfgc age gebac afbcdge egbfc adeb ea | ae ega ecagbd gbacd
|
||||
ecdfb edafbc fe afdcb efc degcb aedf acbgfd ecgfab fecabdg | fe dbegcaf fe cedgfba
|
||||
edbfgc caeb ca cbdafg bcdge bgcdae edfga eacgd gca cgabfed | facebdg ca aedbgc ac
|
||||
gfeba aegc cbfega ea bea dfgbe edfacgb fadgbc gbafc aefcdb | gbecfda bcdfag gcea afcegdb
|
||||
fgcea dc egfdba cdafe gfdecb fbaedc ebdfa dacb bdafgec dec | ced bcfdaeg cefda fagcbed
|
||||
dbefa defacg agd dcbfg bdfagce ga efgbdc abgc fdgab bacfdg | cbga dga gedcfab fdabcg
|
||||
eacbf eac dfagbce cfga fbgea ca bfced agebdc fbedga fcbega | dabfgce gfca ebfacg gbaecf
|
||||
cfagb cgfdea gdc agfcbe fdeacbg bcfdg dg badg fdgacb bcdef | cgd gfacb gd gdba
|
||||
cfga gbadef decabfg cbged baefcd ca cda dbagf fdbcag dbgca | afgebdc bdgeaf gafc cfag
|
||||
cgfbd cdafgb gbcead dbg afdb bgecf adfcg ecbgdfa bd gdacfe | fgacd cgdfa bdaf dbg
|
||||
abf fb febd dbafg febcga gbead egdacb fedgba fbagdce gdcaf | bf fb dbceafg fba
|
||||
fd dgfabe ecafdg deabcg cbefa fed dbgea bdefa bgdf dbfgeca | fde bdfg fdgb gfeabcd
|
||||
fgeadb abfed dgfbcea bafgd agcfd gfb bdfaec bg dgbe cegbaf | egdb fegadbc dcgaf bg
|
||||
fdabc acfbgde dg fcage cdfgab dfebag dga gdafc cdgb eafbcd | gfcad aegdcbf dag afbdc
|
||||
dbfe efdag fgdcae cgbfaed bgfead acebg fb bgf egabf abfcdg | ebdf gfb ebfd fgabed
|
||||
bafegd egcfadb fbc bc fcebgd becaf afbed agecf beacfd bdca | cb dbca cfb afgbcde
|
||||
gbefdc bfead gfcdab gbedca fc cabegdf bedfc fdc cefg cgbde | fdbceg cgfe fc bdcaefg
|
||||
fg dbfea fedagbc cageb aecfdg dfgb dbfaec gafbed begaf gaf | gfecad dgcfea dafeb gfbd
|
||||
dabfg eb egacdfb bfcdga faedc gdeb fbagec aeb bgefad dfeba | bafdcg gfbda gebd be
|
||||
adb dgeabc bfdg gaecfd afdgc cbdgfa bd dcgeafb dafbc bafce | bd fcagbde defagcb dbfg
|
||||
fge bagcf dfaebg fgebc eg cdeg fabcedg bedcf dfcegb acfbde | egcd ecgd cebafd cgdaefb
|
||||
bafdgc gecabf caegf ae beaf gfacb decgf cfedbag aec cdabeg | dcfge ae egcdafb eca
|
||||
fcgba ebgaf agefd agcdfb beac gdbcfe beg bcdfgae gacfbe eb | cfebgd abecdgf ceab abcfdge
|
||||
abcgfd bac feabd adcgeb fcgb bc debgcfa fbdac gceafd fagdc | fbcg gcfad afbed cfbda
|
||||
afdbegc dea abegd agecbd afbgdc dgbfe cabgd afcbed ceag ae | daecbfg cdbag acge ea
|
||||
ebdcg cbfg cdgebf bge adbec eabgdf baecfdg fgadce gedfc bg | dcbae fbcg beg gfbc
|
||||
cfbga cefabg ebfca abeg ae bcedfga gbacfd eac bdefc dcafge | abge fedbc bacgf eac
|
||||
eb aedcg dbfcge cegdbaf gfbe bed dagcbf dacebf dcfgb dbceg | gbef dbe fegb eb
|
||||
cgfe ced dgeba ce cegad abedcf cdaefg cfagbd cadfg gbcedaf | ecgad gcabefd dfbcgae ce
|
||||
dbagc afdc dgfaeb bcfage gbedfac cafbdg cdgeb ac cab gdafb | cab dafbcg dacf acdgfeb
|
||||
dgbae bfa eafgb bafegd fgaec bcfadg fb dbfe egbadc gbecadf | cdegbfa dagfcbe fdeb fab
|
||||
be aecgdf gbdacef bagfc bdef beagf beg dbefag gedfa cbgade | be eb afegb beg
|
||||
cfdagb ac gcfdae cbad bfgda bcfedga begcf afc ebafdg cfbga | deagcf abdc ca cagfb
|
||||
eg efdbga adbcfg ebfcga aefgd bdfga adcbgef defac gbed gae | edbg gedb bfdeag dbcgaf
|
||||
bacegf gbfca cfa ceab gafeb ca gcfdb gadfec dbafge gbdfaec | caf fbgedac fca afc
|
||||
fbagde cbeg afecg gdaecbf fedcga gab efacbg gb acbfg cfdba | gba ecbg agb abgcf
|
||||
abfg dafcgb gcafd bdcgaef ab cba ebdcf bgdaec cfaegd fcbda | acb ecadbg cgdabe fgab
|
||||
agcbd cegdba feagb fd daf gbfad bacdfg cgdfabe dcefab fgcd | df dagbc fgcd fd
|
||||
gdfeabc bcd debaf cb gedfab bcefd edfgc bdceaf aecb cdgbfa | ebac beac cbea abce
|
||||
cbgdef eg beg dbgfc bfgcead gbefd efcg edgbca eabfd acbfdg | gbe gbe cefg gbe
|
||||
fedg begcad gdb bafdge gd egbcaf gdbaf bfacd eacgdbf eafgb | cbefag baegf gefcdab bedgac
|
||||
gbce dcafgb agfdceb efdac acg agcfe aefgb befagd cegfab gc | fbedgac abdefg cga cag
|
||||
gabc bceadf agfcd agd ag fcdgbea gabdef gedfc dbcfa agbfdc | gacb gad bgceadf cbgafde
|
||||
afedc fabced gfcbed feb cegdbaf dbfa ebfac dacfeg fb gbace | feb afdb ebf acfde
|
||||
cbed edgcf ecabdfg ceg cfbgd abgfdc gebfdc ec efbagc gedfa | ec decb ecdb gec
|
||||
egd gfbeac gedcb de dabgfe dcfbg cbefdag eadc dcegba acegb | ed adgfceb gde abcged
|
||||
efadcgb fbdce fagedc agebfd gbafe abedf da bgad ead ceagbf | efagb ecdbf ade aebcgfd
|
||||
cgeb bfaed cbedga cbaed bc bca afgcbd dgface bgfecda decga | fgadcb bca dabfe cab
|
||||
dgaec deagcf egf cdeabg abgdf gdfceab dfcbeg gfead efac ef | agebcd efdbcag aefc bgefcad
|
||||
fbeac gebcaf efa fgce bgfdea dgbcfae gcbdea adcbf ef egacb | gebfacd bfadcge ef eagbc
|
||||
acdbgfe adfg edfcbg efacb egacf gca dgaceb egdcf ga gefcda | fdga cfgae cga ga
|
||||
dfebcg gdaebf dagcf gbaecd dcgebfa bf cfbe bgf bgdce fdbgc | cgbefd bcfe gbf ecbf
|
||||
dcafeg ca acf fcdeb abcfdge facdgb bfagd dfaegb bagc dfbac | dfabgce dfaegc gbafde bacg
|
||||
cgefb cbe cfab afdbeg cb faebg gcfde cefbag ebadgc afdbgec | egbdcfa cbe cafb fecagbd
|
File diff suppressed because it is too large
Load diff
|
@ -1,12 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
#![deny(unsafe_op_in_unsafe_fn)]
|
||||
|
||||
#[derive(PartialEq, Eq, Clone, Copy, Debug)]
|
||||
pub struct LineResult {
|
||||
pub unique_digits: usize,
|
||||
pub number: usize,
|
||||
}
|
||||
|
||||
pub mod v1;
|
||||
pub mod v2;
|
||||
pub mod v3;
|
|
@ -1,23 +0,0 @@
|
|||
#![warn(clippy::pedantic)]
|
||||
use rust_2021_8::{v3::unscramble, LineResult};
|
||||
use std::io::{stdin, BufRead};
|
||||
|
||||
fn main() {
|
||||
let result = stdin()
|
||||
.lock()
|
||||
.lines()
|
||||
.map(|s| unscramble(&s.unwrap()))
|
||||
.fold(
|
||||
LineResult {
|
||||
unique_digits: 0,
|
||||
number: 0,
|
||||
},
|
||||
|a, b| LineResult {
|
||||
unique_digits: a.unique_digits + b.unique_digits,
|
||||
number: a.number + b.number,
|
||||
},
|
||||
);
|
||||
|
||||
println!("{}", result.unique_digits);
|
||||
println!("{}", result.number);
|
||||
}
|
|
@ -1,51 +0,0 @@
|
|||
use std::collections::HashMap;
|
||||
|
||||
use crate::LineResult;
|
||||
|
||||
#[inline]
|
||||
fn lookup(n: usize) -> usize {
|
||||
match n {
|
||||
17 => 1,
|
||||
25 => 7,
|
||||
30 => 4,
|
||||
34 => 2,
|
||||
37 => 5,
|
||||
39 => 3,
|
||||
41 => 6,
|
||||
42 => 0,
|
||||
49 => 8,
|
||||
45 => 9,
|
||||
_ => unreachable!(),
|
||||
}
|
||||
}
|
||||
|
||||
#[inline]
|
||||
#[must_use]
|
||||
pub fn unscramble(line: &str) -> LineResult {
|
||||
let mut parts = line.split('|');
|
||||
let input = parts.next().unwrap();
|
||||
|
||||
let mut counts: HashMap<_, usize> = HashMap::new();
|
||||
for c in input.chars() {
|
||||
*counts.entry(c).or_default() += 1;
|
||||
}
|
||||
|
||||
let digits: Vec<_> = parts
|
||||
.next()
|
||||
.unwrap()
|
||||
.trim()
|
||||
.split(' ')
|
||||
.map(|s| s.chars().map(|c| counts[&c]).sum())
|
||||
.map(lookup)
|
||||
.collect();
|
||||
|
||||
LineResult {
|
||||
unique_digits: digits.iter().filter(|d| [1, 4, 7, 8].contains(d)).count(),
|
||||
number: digits
|
||||
.iter()
|
||||
.map(|&d| char::from_digit(d as u32, 10).unwrap())
|
||||
.collect::<String>()
|
||||
.parse()
|
||||
.unwrap(),
|
||||
}
|
||||
}
|
|
@ -1,47 +0,0 @@
|
|||
use crate::LineResult;
|
||||
use arrayvec::ArrayVec;
|
||||
|
||||
const FREQ_TABLE: [usize; 50] = {
|
||||
let mut tab = [0; 50];
|
||||
tab[17] = 1;
|
||||
tab[25] = 7;
|
||||
tab[30] = 4;
|
||||
tab[34] = 2;
|
||||
tab[37] = 5;
|
||||
tab[39] = 3;
|
||||
tab[41] = 6;
|
||||
tab[42] = 0;
|
||||
tab[45] = 9;
|
||||
tab[49] = 8;
|
||||
tab
|
||||
};
|
||||
|
||||
#[must_use]
|
||||
#[inline]
|
||||
pub fn unscramble(line: &str) -> LineResult {
|
||||
let mut parts = line.split('|');
|
||||
let input = parts.next().unwrap();
|
||||
|
||||
let mut counts = [0; 7];
|
||||
for c in input.bytes() {
|
||||
if (b'a'..=b'g').contains(&c) {
|
||||
counts[c as usize - b'a' as usize] += 1;
|
||||
}
|
||||
}
|
||||
|
||||
let digits = parts
|
||||
.next()
|
||||
.unwrap()
|
||||
.trim_start()
|
||||
.split(' ')
|
||||
.map(|s| s.bytes().map(|c| counts[c as usize - b'a' as usize]).sum())
|
||||
.map(|n: usize| FREQ_TABLE[n])
|
||||
.collect::<ArrayVec<_, 4>>()
|
||||
.into_inner()
|
||||
.unwrap();
|
||||
|
||||
LineResult {
|
||||
unique_digits: digits.iter().filter(|d| [1, 4, 7, 8].contains(d)).count(),
|
||||
number: digits.iter().fold(0, |acc, d| acc * 10 + d),
|
||||
}
|
||||
}
|
|
@ -1,64 +0,0 @@
|
|||
use crate::LineResult;
|
||||
|
||||
const FREQ_TABLE: [usize; 256] = {
|
||||
let mut tab = [0; 256];
|
||||
tab[17] = 1;
|
||||
tab[25] = 7;
|
||||
tab[30] = 4;
|
||||
tab[34] = 2;
|
||||
tab[37] = 5;
|
||||
tab[39] = 3;
|
||||
tab[41] = 6;
|
||||
tab[42] = 0;
|
||||
tab[45] = 9;
|
||||
tab[49] = 8;
|
||||
tab
|
||||
};
|
||||
|
||||
#[must_use]
|
||||
#[inline]
|
||||
pub fn unscramble(line: &str) -> LineResult {
|
||||
let mut bytes = line.bytes();
|
||||
|
||||
let mut counts = [0; 7];
|
||||
loop {
|
||||
match bytes.next().unwrap() {
|
||||
c @ b'a'..=b'g' => {
|
||||
counts[c as usize - b'a' as usize] += 1;
|
||||
}
|
||||
b'|' => break,
|
||||
_ => {}
|
||||
}
|
||||
}
|
||||
|
||||
bytes.next();
|
||||
|
||||
let mut freq = 0;
|
||||
let mut unique_digits = 0;
|
||||
let mut number = 0;
|
||||
loop {
|
||||
let c = bytes.next();
|
||||
match c {
|
||||
Some(b' ') | None => {
|
||||
let digit = FREQ_TABLE[freq & 0xff];
|
||||
if [1, 4, 7, 8].contains(&digit) {
|
||||
unique_digits += 1;
|
||||
}
|
||||
number = number * 10 + digit;
|
||||
freq = 0;
|
||||
if c.is_none() {
|
||||
break;
|
||||
}
|
||||
}
|
||||
Some(c @ b'a'..=b'g') => {
|
||||
freq += counts[c as usize - b'a' as usize];
|
||||
}
|
||||
Some(_) => {}
|
||||
}
|
||||
}
|
||||
|
||||
LineResult {
|
||||
unique_digits,
|
||||
number,
|
||||
}
|
||||
}
|
|
@ -1,72 +0,0 @@
|
|||
use std::path::PathBuf;
|
||||
|
||||
use rust_2021_8::{v1, v2, v3, LineResult};
|
||||
|
||||
fn test_unscramble_with_input(f: fn(&str) -> LineResult, input: &[&str]) -> LineResult {
|
||||
let mut result = LineResult {
|
||||
unique_digits: 0,
|
||||
number: 0,
|
||||
};
|
||||
|
||||
for line in input {
|
||||
let LineResult {
|
||||
unique_digits,
|
||||
number,
|
||||
} = f(line);
|
||||
result.unique_digits += unique_digits;
|
||||
result.number += number;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
fn test_unscramble(f: fn(&str) -> LineResult) {
|
||||
let test_file = |name| {
|
||||
let mut path = PathBuf::from(env!("CARGO_MANIFEST_DIR"));
|
||||
path.push("inputs/");
|
||||
path.push(name);
|
||||
|
||||
let input = std::fs::read_to_string(path).unwrap();
|
||||
let input: Vec<_> = input.lines().collect();
|
||||
test_unscramble_with_input(f, &input)
|
||||
};
|
||||
|
||||
assert_eq!(
|
||||
test_file("example.txt"),
|
||||
LineResult {
|
||||
unique_digits: 26,
|
||||
number: 61229
|
||||
}
|
||||
);
|
||||
|
||||
assert_eq!(
|
||||
test_file("input.txt"),
|
||||
LineResult {
|
||||
unique_digits: 543,
|
||||
number: 994266
|
||||
}
|
||||
);
|
||||
|
||||
assert_eq!(
|
||||
test_file("large.txt"),
|
||||
LineResult {
|
||||
unique_digits: 159946,
|
||||
number: 498570828
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
pub fn test_unscramble_v1() {
|
||||
test_unscramble(v1::unscramble)
|
||||
}
|
||||
|
||||
#[test]
|
||||
pub fn test_unscramble_v2() {
|
||||
test_unscramble(v2::unscramble)
|
||||
}
|
||||
|
||||
#[test]
|
||||
pub fn test_unscramble_v3() {
|
||||
test_unscramble(v3::unscramble)
|
||||
}
|
|
@ -1,62 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
from collections import Counter
|
||||
from dataclasses import dataclass
|
||||
import math
|
||||
import sys
|
||||
from typing import Optional, Tuple
|
||||
|
||||
@dataclass
|
||||
class Point:
|
||||
height: int
|
||||
low_point: Optional[Tuple[int, int]]
|
||||
|
||||
class Grid:
|
||||
def __init__(self, data):
|
||||
self.data = data
|
||||
self.rows = len(data)
|
||||
self.cols = len(data[0])
|
||||
|
||||
def get(self, x, y):
|
||||
if 0 <= x < self.rows and 0 <= y < self.cols:
|
||||
return self.data[x][y]
|
||||
else:
|
||||
return None
|
||||
|
||||
def find_low_point(self, x, y):
|
||||
current = self.get(x, y)
|
||||
if current is None:
|
||||
raise ValueError
|
||||
|
||||
if current.low_point is not None:
|
||||
return current.low_point
|
||||
if current.height == 9:
|
||||
return None
|
||||
|
||||
for dx, dy in ((-1, 0), (1, 0), (0, -1), (0, 1)):
|
||||
target = self.get(x+dx, y+dy)
|
||||
if target is not None:
|
||||
if target.height < current.height:
|
||||
current.low_point = self.find_low_point(x+dx, y+dy)
|
||||
return current.low_point
|
||||
return (x, y)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
grid = Grid([
|
||||
[
|
||||
Point(height=int(n), low_point=None)
|
||||
for n in i.strip()
|
||||
]
|
||||
for i in sys.stdin.readlines()
|
||||
])
|
||||
|
||||
counts = Counter()
|
||||
for x in range(grid.rows):
|
||||
for y in range(grid.cols):
|
||||
low_point = grid.find_low_point(x, y)
|
||||
if low_point is not None:
|
||||
counts.update([low_point])
|
||||
|
||||
print(sum(grid.get(x, y).height + 1 for x, y in counts.keys()))
|
||||
print(math.prod(c for _, c in counts.most_common(3)))
|
|
@ -1,50 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
import itertools
|
||||
|
||||
def walk_up(grid, x_orig, y_orig):
|
||||
rows = len(grid)
|
||||
cols = len(grid[0])
|
||||
current = grid[x_orig][y_orig]
|
||||
points = set()
|
||||
for dx in (-1, 0, +1):
|
||||
for dy in (-1, 0, +1):
|
||||
if (dx == 0) == (dy == 0):
|
||||
continue
|
||||
x = x_orig + dx
|
||||
y = y_orig + dy
|
||||
if 0 <= x < rows and 0 <= y < cols:
|
||||
if current < grid[x][y] < 9:
|
||||
points.add((x, y))
|
||||
points |= walk_up(grid, x, y)
|
||||
return points
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
inp = [[int(n) for n in i.strip()] for i in sys.stdin.readlines()]
|
||||
|
||||
rows = len(inp)
|
||||
cols = len(inp[0])
|
||||
acc = 0
|
||||
sizes = []
|
||||
for x, row in enumerate(inp):
|
||||
for y, n in enumerate(row):
|
||||
if y > 0 and row[y-1] <= n:
|
||||
continue
|
||||
if y < cols-1 and row[y+1] <= n:
|
||||
continue
|
||||
if x > 0 and inp[x-1][y] <= n:
|
||||
continue
|
||||
if x < rows-1 and inp[x+1][y] <= n:
|
||||
continue
|
||||
points = walk_up(inp, x, y)
|
||||
points.add((x, y))
|
||||
sizes.append(len(points))
|
||||
acc += n + 1
|
||||
sizes.sort()
|
||||
print(acc)
|
||||
acc2 = 1
|
||||
for x in sizes[-3:]:
|
||||
acc2 *= x
|
||||
print(acc2)
|
|
@ -1,2 +0,0 @@
|
|||
72017
|
||||
212520
|
2238
2022/data/day1.input
2238
2022/data/day1.input
File diff suppressed because it is too large
Load diff
|
@ -1,7 +0,0 @@
|
|||
13520
|
||||
###...##..###..#..#.###..####..##..###..
|
||||
#..#.#..#.#..#.#..#.#..#.#....#..#.#..#.
|
||||
#..#.#....#..#.####.###..###..#..#.###..
|
||||
###..#.##.###..#..#.#..#.#....####.#..#.
|
||||
#....#..#.#....#..#.#..#.#....#..#.#..#.
|
||||
#.....###.#....#..#.###..####.#..#.###..
|
|
@ -1,147 +0,0 @@
|
|||
noop
|
||||
noop
|
||||
noop
|
||||
addx 6
|
||||
addx -1
|
||||
addx 5
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx 5
|
||||
addx 11
|
||||
addx -10
|
||||
addx 4
|
||||
noop
|
||||
addx 5
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx 1
|
||||
noop
|
||||
addx 4
|
||||
addx 5
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx -35
|
||||
addx -2
|
||||
addx 5
|
||||
addx 2
|
||||
addx 3
|
||||
addx -2
|
||||
addx 2
|
||||
addx 5
|
||||
addx 2
|
||||
addx 3
|
||||
addx -2
|
||||
addx 2
|
||||
addx 5
|
||||
addx 2
|
||||
addx 3
|
||||
addx -28
|
||||
addx 28
|
||||
addx 5
|
||||
addx 2
|
||||
addx -9
|
||||
addx 10
|
||||
addx -38
|
||||
noop
|
||||
addx 3
|
||||
addx 2
|
||||
addx 7
|
||||
noop
|
||||
noop
|
||||
addx -9
|
||||
addx 10
|
||||
addx 4
|
||||
addx 2
|
||||
addx 3
|
||||
noop
|
||||
noop
|
||||
addx -2
|
||||
addx 7
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx 3
|
||||
addx 5
|
||||
addx 2
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx -35
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx 5
|
||||
addx 2
|
||||
noop
|
||||
addx 3
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx 5
|
||||
addx 3
|
||||
addx -2
|
||||
addx 2
|
||||
addx 5
|
||||
addx 2
|
||||
addx -25
|
||||
noop
|
||||
addx 30
|
||||
noop
|
||||
addx 1
|
||||
noop
|
||||
addx 2
|
||||
noop
|
||||
addx 3
|
||||
addx -38
|
||||
noop
|
||||
addx 7
|
||||
addx -2
|
||||
addx 5
|
||||
addx 2
|
||||
addx -8
|
||||
addx 13
|
||||
addx -2
|
||||
noop
|
||||
addx 3
|
||||
addx 2
|
||||
addx 5
|
||||
addx 2
|
||||
addx -15
|
||||
noop
|
||||
addx 20
|
||||
addx 3
|
||||
noop
|
||||
addx 2
|
||||
addx -4
|
||||
addx 5
|
||||
addx -38
|
||||
addx 8
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
addx 2
|
||||
addx 17
|
||||
addx -10
|
||||
addx 3
|
||||
noop
|
||||
addx 2
|
||||
addx 1
|
||||
addx -16
|
||||
addx 19
|
||||
addx 2
|
||||
noop
|
||||
addx 2
|
||||
addx 5
|
||||
addx 2
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
noop
|
||||
noop
|
|
@ -1,2 +0,0 @@
|
|||
66124
|
||||
19309892877
|
|
@ -1,55 +0,0 @@
|
|||
Monkey 0:
|
||||
Starting items: 75, 75, 98, 97, 79, 97, 64
|
||||
Operation: new = old * 13
|
||||
Test: divisible by 19
|
||||
If true: throw to monkey 2
|
||||
If false: throw to monkey 7
|
||||
|
||||
Monkey 1:
|
||||
Starting items: 50, 99, 80, 84, 65, 95
|
||||
Operation: new = old + 2
|
||||
Test: divisible by 3
|
||||
If true: throw to monkey 4
|
||||
If false: throw to monkey 5
|
||||
|
||||
Monkey 2:
|
||||
Starting items: 96, 74, 68, 96, 56, 71, 75, 53
|
||||
Operation: new = old + 1
|
||||
Test: divisible by 11
|
||||
If true: throw to monkey 7
|
||||
If false: throw to monkey 3
|
||||
|
||||
Monkey 3:
|
||||
Starting items: 83, 96, 86, 58, 92
|
||||
Operation: new = old + 8
|
||||
Test: divisible by 17
|
||||
If true: throw to monkey 6
|
||||
If false: throw to monkey 1
|
||||
|
||||
Monkey 4:
|
||||
Starting items: 99
|
||||
Operation: new = old * old
|
||||
Test: divisible by 5
|
||||
If true: throw to monkey 0
|
||||
If false: throw to monkey 5
|
||||
|
||||
Monkey 5:
|
||||
Starting items: 60, 54, 83
|
||||
Operation: new = old + 4
|
||||
Test: divisible by 2
|
||||
If true: throw to monkey 2
|
||||
If false: throw to monkey 0
|
||||
|
||||
Monkey 6:
|
||||
Starting items: 77, 67
|
||||
Operation: new = old * 17
|
||||
Test: divisible by 13
|
||||
If true: throw to monkey 4
|
||||
If false: throw to monkey 1
|
||||
|
||||
Monkey 7:
|
||||
Starting items: 95, 65, 58, 76
|
||||
Operation: new = old + 5
|
||||
Test: divisible by 7
|
||||
If true: throw to monkey 3
|
||||
If false: throw to monkey 6
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue