Compare commits
87 Commits
742f35b73e
...
main
Author | SHA1 | Date | |
---|---|---|---|
c2d5545139 | |||
466d79e81a | |||
911a60ab6c | |||
985b88f0aa | |||
cd42646864 | |||
5ce4e2b51b | |||
a83cef34f0 | |||
78df584c4d | |||
4cb23761b2 | |||
5296af36dd | |||
b410fa49ca | |||
27a236f958 | |||
e55dcd47a3 | |||
ff241d76cb | |||
6e3d6625ee | |||
b20aa6fbdc | |||
312460ffa5 | |||
86c52a1a59 | |||
f56780d1cf | |||
fa842890ce | |||
548f1b3d73 | |||
2299375c7c | |||
93ce6d0719 | |||
c46843cf5a | |||
dd6e9dbe90 | |||
64cb7fb370 | |||
99430e8e26 | |||
0dec0bbf82 | |||
2a91587ae5 | |||
dbf878baf1 | |||
013b85fbbf | |||
4dcf7001ee | |||
05c88e5e56 | |||
4c62525fa7 | |||
fa52f5bd13 | |||
a141026754 | |||
6abd6c7d66 | |||
b429585457 | |||
5a17373244 | |||
eae352413b | |||
0b4e2449a1 | |||
daead25413 | |||
5b2e4a38d1 | |||
4e6399f5e2 | |||
1db00c45db | |||
a6731d4a67 | |||
5bd059970e | |||
9329c9f77a | |||
67d3a56011 | |||
|
a1183f8ef4 | ||
|
5531e8aa7a | ||
|
cd1249a5fe | ||
3bb1616d7e | |||
00692c18df | |||
a875d889fa | |||
46deb678df | |||
33e6f1241c | |||
|
7d0ed36699 | ||
5015474745 | |||
1d9c848525 | |||
36bb36803a | |||
aa28df24b3 | |||
2d6e0155bc | |||
261a2e89c9 | |||
fcf0a0866c | |||
16ed2a8cae | |||
2f37793f02 | |||
0d2fd4b451 | |||
d31ff0dd3a | |||
9438245d84 | |||
ca267835d1 | |||
|
7f93abc07d | ||
19d548018a | |||
|
a687f18918 | ||
eacf990729 | |||
828566cce3 | |||
15be81c564 | |||
b55df3d448 | |||
3486d23f09 | |||
ea1e7aadec | |||
19f50f48d6 | |||
d002880b83 | |||
b2403336a5 | |||
5f7d4ea185 | |||
1979821775 | |||
04ae9d47ef | |||
25be019d72 |
128
Cargo.lock
generated
128
Cargo.lock
generated
@@ -2,22 +2,141 @@
|
|||||||
# It is not intended for manual editing.
|
# It is not intended for manual editing.
|
||||||
version = 4
|
version = 4
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "aho-corasick"
|
||||||
|
version = "1.1.3"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916"
|
||||||
|
dependencies = [
|
||||||
|
"memchr",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "crossbeam-deque"
|
||||||
|
version = "0.8.6"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "9dd111b7b7f7d55b72c0a6ae361660ee5853c9af73f70c3c2ef6858b950e2e51"
|
||||||
|
dependencies = [
|
||||||
|
"crossbeam-epoch",
|
||||||
|
"crossbeam-utils",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "crossbeam-epoch"
|
||||||
|
version = "0.9.18"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e"
|
||||||
|
dependencies = [
|
||||||
|
"crossbeam-utils",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "crossbeam-utils"
|
||||||
|
version = "0.8.21"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "d0a5c400df2834b80a4c3327b3aad3a4c4cd4de0629063962b03235697506a28"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "either"
|
||||||
|
version = "1.13.0"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "genaoc"
|
||||||
|
version = "0.1.0"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "itertools"
|
||||||
|
version = "0.13.0"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186"
|
||||||
|
dependencies = [
|
||||||
|
"either",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "md5"
|
name = "md5"
|
||||||
version = "0.7.0"
|
version = "0.7.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "490cc448043f947bae3cbee9c203358d62dbee0db12107a74be5c30ccfd09771"
|
checksum = "490cc448043f947bae3cbee9c203358d62dbee0db12107a74be5c30ccfd09771"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "memchr"
|
||||||
|
version = "2.7.4"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "rayon"
|
||||||
|
version = "1.10.0"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa"
|
||||||
|
dependencies = [
|
||||||
|
"either",
|
||||||
|
"rayon-core",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "rayon-core"
|
||||||
|
version = "1.12.1"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2"
|
||||||
|
dependencies = [
|
||||||
|
"crossbeam-deque",
|
||||||
|
"crossbeam-utils",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "regex"
|
||||||
|
version = "1.11.1"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191"
|
||||||
|
dependencies = [
|
||||||
|
"aho-corasick",
|
||||||
|
"memchr",
|
||||||
|
"regex-automata",
|
||||||
|
"regex-syntax",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "regex-automata"
|
||||||
|
version = "0.4.9"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "809e8dc61f6de73b46c85f4c96486310fe304c434cfa43669d7b40f711150908"
|
||||||
|
dependencies = [
|
||||||
|
"aho-corasick",
|
||||||
|
"memchr",
|
||||||
|
"regex-syntax",
|
||||||
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "regex-syntax"
|
||||||
|
version = "0.8.5"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "utils"
|
||||||
|
version = "0.1.0"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "y2015"
|
name = "y2015"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
"itertools",
|
||||||
"md5",
|
"md5",
|
||||||
|
"utils",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "y2016"
|
name = "y2016"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
|
dependencies = [
|
||||||
|
"itertools",
|
||||||
|
"md5",
|
||||||
|
"utils",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "y2017"
|
name = "y2017"
|
||||||
@@ -42,6 +161,9 @@ version = "0.1.0"
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "y2022"
|
name = "y2022"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
|
dependencies = [
|
||||||
|
"utils",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "y2023"
|
name = "y2023"
|
||||||
@@ -50,3 +172,9 @@ version = "0.1.0"
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "y2024"
|
name = "y2024"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
|
dependencies = [
|
||||||
|
"itertools",
|
||||||
|
"rayon",
|
||||||
|
"regex",
|
||||||
|
"utils",
|
||||||
|
]
|
||||||
|
12
Cargo.toml
12
Cargo.toml
@@ -1,3 +1,8 @@
|
|||||||
|
[package]
|
||||||
|
name = "genaoc"
|
||||||
|
version = "0.1.0"
|
||||||
|
edition = "2021"
|
||||||
|
|
||||||
[workspace]
|
[workspace]
|
||||||
resolver = "2"
|
resolver = "2"
|
||||||
members = [
|
members = [
|
||||||
@@ -12,3 +17,10 @@ members = [
|
|||||||
"y2023",
|
"y2023",
|
||||||
"y2024",
|
"y2024",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[workspace.dependencies]
|
||||||
|
utils = { path = "../utils" }
|
||||||
|
itertools = "0.13.0"
|
||||||
|
regex = "1.11.1"
|
||||||
|
md5 = "0.7.0"
|
||||||
|
rayon = "1.10"
|
||||||
|
8
justfile
Normal file
8
justfile
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
gen year *day:
|
||||||
|
cargo run -- {{year}} {{day}}
|
||||||
|
|
||||||
|
run year day:
|
||||||
|
cargo run --package y{{year}} --bin d{{day}}
|
||||||
|
|
||||||
|
test year day *part='1':
|
||||||
|
cargo test --package y{{year}} --lib days::d{{day}}::tests::part{{part}} -- --nocapture
|
64
src/main.rs
Normal file
64
src/main.rs
Normal file
@@ -0,0 +1,64 @@
|
|||||||
|
use std::{env, fs, path::Path, process::Command};
|
||||||
|
|
||||||
|
fn main() -> Result<(), std::io::Error> {
|
||||||
|
let args: Vec<String> = env::args().collect();
|
||||||
|
|
||||||
|
if args.len() == 1 {
|
||||||
|
println!("Too few arguments");
|
||||||
|
println!("Please enter a year, or a year and day");
|
||||||
|
return Err(std::io::ErrorKind::InvalidInput.into());
|
||||||
|
} else if args.len() > 3 {
|
||||||
|
println!("Too many arguments");
|
||||||
|
println!("Please enter a year, or a year and day");
|
||||||
|
return Err(std::io::ErrorKind::InvalidInput.into());
|
||||||
|
} else if args.len() == 2 {
|
||||||
|
prepare_year(&args[1])?;
|
||||||
|
} else if args.len() == 3 {
|
||||||
|
prepare_day(&args[1], &args[2])?;
|
||||||
|
}
|
||||||
|
match Command::new("cargo").arg("fmt").status() {
|
||||||
|
Ok(_) => Ok(()),
|
||||||
|
Err(e) => Err(e),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn prepare_year(year: &str) -> Result<(), std::io::Error> {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
if Path::new(&format!("{root}/y{year}")).exists() {
|
||||||
|
panic!("Folder y{year} already exists")
|
||||||
|
}
|
||||||
|
// create workspace
|
||||||
|
match Command::new("cargo")
|
||||||
|
.arg("new")
|
||||||
|
.arg(format!("y{year}"))
|
||||||
|
.status()
|
||||||
|
{
|
||||||
|
Ok(_status) => Ok(()),
|
||||||
|
Err(e) => Err(e),
|
||||||
|
}?;
|
||||||
|
// remove main.rs
|
||||||
|
fs::remove_file(format!("{root}/y{year}/src/main.rs"))?;
|
||||||
|
fs::create_dir(format!("{root}/y{year}/src/bin"))?;
|
||||||
|
fs::create_dir(format!("{root}/y{year}/src/days"))?;
|
||||||
|
fs::write(format!("{root}/y{year}/src/lib.rs"), "pub mod days;")?;
|
||||||
|
fs::write(format!("{root}/y{year}/src/days/mod.rs"), "")?;
|
||||||
|
prepare_day(year, "1")
|
||||||
|
}
|
||||||
|
|
||||||
|
fn prepare_day(year: &str, day: &str) -> Result<(), std::io::Error> {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
if Path::new(&format!("{root}/y{year}/src/bin/d{day}.rs")).exists() {
|
||||||
|
panic!("Day y{year}d{day} already exists")
|
||||||
|
}
|
||||||
|
let bin = fs::read_to_string(format!("{root}/template/bin/d.rs.tmpl"))?
|
||||||
|
.replace("{{YEAR}}", year)
|
||||||
|
.replace("{{DAY}}", day);
|
||||||
|
let dayfile = fs::read_to_string(format!("{root}/template/days/d.rs.tmpl"))?;
|
||||||
|
let mut modfile = fs::read_to_string(format!("{root}/y{year}/src/days/mod.rs"))?;
|
||||||
|
modfile.push_str(format!("\npub mod d{day};").as_str());
|
||||||
|
let bin_path = format!("{root}/y{year}/src/bin/d{day}.rs");
|
||||||
|
fs::write(bin_path, bin)?;
|
||||||
|
fs::write(format!("{root}/y{year}/src/days/d{day}.rs"), dayfile)?;
|
||||||
|
fs::write(format!("{root}/y{year}/src/days/mod.rs"), modfile)?;
|
||||||
|
Ok(())
|
||||||
|
}
|
27
template/bin/d.rs.tmpl
Normal file
27
template/bin/d.rs.tmpl
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y{{YEAR}}::days::d{{DAY}};
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/{{DAY}}_input.txt")).unwrap();
|
||||||
|
println!("{}", d{{DAY}}::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/{{DAY}}_input.txt")).unwrap();
|
||||||
|
println!("{}", d{{DAY}}::process_part2(&content));
|
||||||
|
}
|
26
template/days/d.rs.tmpl
Normal file
26
template/days/d.rs.tmpl
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
pub fn process_part1(input: &str) -> i32 {
|
||||||
|
0
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> i32 {
|
||||||
|
0
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "{{EXAMPLE}}";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, 0);
|
||||||
|
}
|
||||||
|
}
|
@@ -4,4 +4,6 @@ version = "0.1.0"
|
|||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
md5 = "0.7.0"
|
md5 = { workspace = true }
|
||||||
|
utils = { workspace = true }
|
||||||
|
itertools = { workspace = true }
|
||||||
|
1
y2015/resources/12_input.txt
Normal file
1
y2015/resources/12_input.txt
Normal file
File diff suppressed because one or more lines are too long
56
y2015/resources/13_input.txt
Normal file
56
y2015/resources/13_input.txt
Normal file
@@ -0,0 +1,56 @@
|
|||||||
|
Alice would gain 54 happiness units by sitting next to Bob.
|
||||||
|
Alice would lose 81 happiness units by sitting next to Carol.
|
||||||
|
Alice would lose 42 happiness units by sitting next to David.
|
||||||
|
Alice would gain 89 happiness units by sitting next to Eric.
|
||||||
|
Alice would lose 89 happiness units by sitting next to Frank.
|
||||||
|
Alice would gain 97 happiness units by sitting next to George.
|
||||||
|
Alice would lose 94 happiness units by sitting next to Mallory.
|
||||||
|
Bob would gain 3 happiness units by sitting next to Alice.
|
||||||
|
Bob would lose 70 happiness units by sitting next to Carol.
|
||||||
|
Bob would lose 31 happiness units by sitting next to David.
|
||||||
|
Bob would gain 72 happiness units by sitting next to Eric.
|
||||||
|
Bob would lose 25 happiness units by sitting next to Frank.
|
||||||
|
Bob would lose 95 happiness units by sitting next to George.
|
||||||
|
Bob would gain 11 happiness units by sitting next to Mallory.
|
||||||
|
Carol would lose 83 happiness units by sitting next to Alice.
|
||||||
|
Carol would gain 8 happiness units by sitting next to Bob.
|
||||||
|
Carol would gain 35 happiness units by sitting next to David.
|
||||||
|
Carol would gain 10 happiness units by sitting next to Eric.
|
||||||
|
Carol would gain 61 happiness units by sitting next to Frank.
|
||||||
|
Carol would gain 10 happiness units by sitting next to George.
|
||||||
|
Carol would gain 29 happiness units by sitting next to Mallory.
|
||||||
|
David would gain 67 happiness units by sitting next to Alice.
|
||||||
|
David would gain 25 happiness units by sitting next to Bob.
|
||||||
|
David would gain 48 happiness units by sitting next to Carol.
|
||||||
|
David would lose 65 happiness units by sitting next to Eric.
|
||||||
|
David would gain 8 happiness units by sitting next to Frank.
|
||||||
|
David would gain 84 happiness units by sitting next to George.
|
||||||
|
David would gain 9 happiness units by sitting next to Mallory.
|
||||||
|
Eric would lose 51 happiness units by sitting next to Alice.
|
||||||
|
Eric would lose 39 happiness units by sitting next to Bob.
|
||||||
|
Eric would gain 84 happiness units by sitting next to Carol.
|
||||||
|
Eric would lose 98 happiness units by sitting next to David.
|
||||||
|
Eric would lose 20 happiness units by sitting next to Frank.
|
||||||
|
Eric would lose 6 happiness units by sitting next to George.
|
||||||
|
Eric would gain 60 happiness units by sitting next to Mallory.
|
||||||
|
Frank would gain 51 happiness units by sitting next to Alice.
|
||||||
|
Frank would gain 79 happiness units by sitting next to Bob.
|
||||||
|
Frank would gain 88 happiness units by sitting next to Carol.
|
||||||
|
Frank would gain 33 happiness units by sitting next to David.
|
||||||
|
Frank would gain 43 happiness units by sitting next to Eric.
|
||||||
|
Frank would gain 77 happiness units by sitting next to George.
|
||||||
|
Frank would lose 3 happiness units by sitting next to Mallory.
|
||||||
|
George would lose 14 happiness units by sitting next to Alice.
|
||||||
|
George would lose 12 happiness units by sitting next to Bob.
|
||||||
|
George would lose 52 happiness units by sitting next to Carol.
|
||||||
|
George would gain 14 happiness units by sitting next to David.
|
||||||
|
George would lose 62 happiness units by sitting next to Eric.
|
||||||
|
George would lose 18 happiness units by sitting next to Frank.
|
||||||
|
George would lose 17 happiness units by sitting next to Mallory.
|
||||||
|
Mallory would lose 36 happiness units by sitting next to Alice.
|
||||||
|
Mallory would gain 76 happiness units by sitting next to Bob.
|
||||||
|
Mallory would lose 34 happiness units by sitting next to Carol.
|
||||||
|
Mallory would gain 37 happiness units by sitting next to David.
|
||||||
|
Mallory would gain 40 happiness units by sitting next to Eric.
|
||||||
|
Mallory would gain 18 happiness units by sitting next to Frank.
|
||||||
|
Mallory would gain 7 happiness units by sitting next to George.
|
9
y2015/resources/14_input.txt
Normal file
9
y2015/resources/14_input.txt
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
Vixen can fly 19 km/s for 7 seconds, but then must rest for 124 seconds.
|
||||||
|
Rudolph can fly 3 km/s for 15 seconds, but then must rest for 28 seconds.
|
||||||
|
Donner can fly 19 km/s for 9 seconds, but then must rest for 164 seconds.
|
||||||
|
Blitzen can fly 19 km/s for 9 seconds, but then must rest for 158 seconds.
|
||||||
|
Comet can fly 13 km/s for 7 seconds, but then must rest for 82 seconds.
|
||||||
|
Cupid can fly 25 km/s for 6 seconds, but then must rest for 145 seconds.
|
||||||
|
Dasher can fly 14 km/s for 3 seconds, but then must rest for 38 seconds.
|
||||||
|
Dancer can fly 3 km/s for 16 seconds, but then must rest for 37 seconds.
|
||||||
|
Prancer can fly 25 km/s for 6 seconds, but then must rest for 143 seconds.
|
4
y2015/resources/15_input.txt
Normal file
4
y2015/resources/15_input.txt
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
Sprinkles: capacity 2, durability 0, flavor -2, texture 0, calories 3
|
||||||
|
Butterscotch: capacity 0, durability 5, flavor -3, texture 0, calories 3
|
||||||
|
Chocolate: capacity 0, durability 0, flavor 5, texture -1, calories 8
|
||||||
|
Candy: capacity 0, durability -1, flavor 0, texture 5, calories 8
|
500
y2015/resources/16_input.txt
Normal file
500
y2015/resources/16_input.txt
Normal file
@@ -0,0 +1,500 @@
|
|||||||
|
Sue 1: goldfish: 9, cars: 0, samoyeds: 9
|
||||||
|
Sue 2: perfumes: 5, trees: 8, goldfish: 8
|
||||||
|
Sue 3: pomeranians: 2, akitas: 1, trees: 5
|
||||||
|
Sue 4: goldfish: 10, akitas: 2, perfumes: 9
|
||||||
|
Sue 5: cars: 5, perfumes: 6, akitas: 9
|
||||||
|
Sue 6: goldfish: 10, cats: 9, cars: 8
|
||||||
|
Sue 7: trees: 2, samoyeds: 7, goldfish: 10
|
||||||
|
Sue 8: cars: 8, perfumes: 6, goldfish: 1
|
||||||
|
Sue 9: cats: 4, pomeranians: 0, trees: 0
|
||||||
|
Sue 10: trees: 2, children: 10, samoyeds: 10
|
||||||
|
Sue 11: akitas: 10, perfumes: 4, vizslas: 1
|
||||||
|
Sue 12: akitas: 1, trees: 0, goldfish: 3
|
||||||
|
Sue 13: perfumes: 6, goldfish: 10, cars: 8
|
||||||
|
Sue 14: cats: 8, akitas: 5, vizslas: 0
|
||||||
|
Sue 15: cars: 8, trees: 3, samoyeds: 5
|
||||||
|
Sue 16: vizslas: 6, cats: 6, pomeranians: 10
|
||||||
|
Sue 17: akitas: 6, cats: 2, perfumes: 9
|
||||||
|
Sue 18: children: 9, goldfish: 2, akitas: 10
|
||||||
|
Sue 19: trees: 3, perfumes: 0, goldfish: 6
|
||||||
|
Sue 20: vizslas: 3, akitas: 0, trees: 1
|
||||||
|
Sue 21: vizslas: 3, cars: 7, akitas: 3
|
||||||
|
Sue 22: perfumes: 7, children: 1, pomeranians: 7
|
||||||
|
Sue 23: trees: 10, cars: 9, akitas: 10
|
||||||
|
Sue 24: akitas: 5, goldfish: 6, vizslas: 6
|
||||||
|
Sue 25: samoyeds: 3, trees: 8, vizslas: 5
|
||||||
|
Sue 26: vizslas: 4, pomeranians: 2, trees: 1
|
||||||
|
Sue 27: cars: 9, goldfish: 2, trees: 4
|
||||||
|
Sue 28: vizslas: 6, goldfish: 10, perfumes: 7
|
||||||
|
Sue 29: vizslas: 6, pomeranians: 3, akitas: 6
|
||||||
|
Sue 30: trees: 0, samoyeds: 5, akitas: 9
|
||||||
|
Sue 31: vizslas: 1, perfumes: 0, trees: 6
|
||||||
|
Sue 32: cars: 7, vizslas: 1, children: 10
|
||||||
|
Sue 33: vizslas: 1, cars: 1, perfumes: 7
|
||||||
|
Sue 34: vizslas: 9, trees: 10, akitas: 9
|
||||||
|
Sue 35: akitas: 3, vizslas: 5, cars: 10
|
||||||
|
Sue 36: cats: 3, children: 9, samoyeds: 3
|
||||||
|
Sue 37: vizslas: 5, pomeranians: 7, cars: 6
|
||||||
|
Sue 38: cars: 10, akitas: 5, vizslas: 8
|
||||||
|
Sue 39: akitas: 5, trees: 9, children: 2
|
||||||
|
Sue 40: vizslas: 0, cats: 7, akitas: 0
|
||||||
|
Sue 41: cars: 9, trees: 10, perfumes: 8
|
||||||
|
Sue 42: akitas: 4, trees: 2, goldfish: 3
|
||||||
|
Sue 43: goldfish: 1, cats: 1, akitas: 8
|
||||||
|
Sue 44: goldfish: 8, akitas: 9, vizslas: 4
|
||||||
|
Sue 45: perfumes: 3, goldfish: 4, trees: 0
|
||||||
|
Sue 46: trees: 7, perfumes: 1, goldfish: 8
|
||||||
|
Sue 47: pomeranians: 10, cars: 7, trees: 2
|
||||||
|
Sue 48: trees: 2, akitas: 1, cars: 4
|
||||||
|
Sue 49: goldfish: 5, perfumes: 7, akitas: 8
|
||||||
|
Sue 50: akitas: 9, vizslas: 9, trees: 2
|
||||||
|
Sue 51: cars: 0, samoyeds: 0, vizslas: 8
|
||||||
|
Sue 52: trees: 0, perfumes: 6, pomeranians: 4
|
||||||
|
Sue 53: vizslas: 1, cats: 6, akitas: 3
|
||||||
|
Sue 54: samoyeds: 8, akitas: 1, vizslas: 4
|
||||||
|
Sue 55: goldfish: 10, perfumes: 2, pomeranians: 10
|
||||||
|
Sue 56: trees: 9, perfumes: 3, goldfish: 5
|
||||||
|
Sue 57: akitas: 3, perfumes: 0, cats: 2
|
||||||
|
Sue 58: perfumes: 4, vizslas: 4, cars: 8
|
||||||
|
Sue 59: goldfish: 7, children: 5, pomeranians: 8
|
||||||
|
Sue 60: cars: 1, trees: 1, perfumes: 10
|
||||||
|
Sue 61: trees: 4, samoyeds: 4, cars: 6
|
||||||
|
Sue 62: akitas: 10, trees: 2, vizslas: 6
|
||||||
|
Sue 63: goldfish: 3, perfumes: 7, vizslas: 10
|
||||||
|
Sue 64: pomeranians: 5, children: 10, cars: 0
|
||||||
|
Sue 65: vizslas: 10, cars: 8, perfumes: 3
|
||||||
|
Sue 66: children: 5, vizslas: 4, akitas: 10
|
||||||
|
Sue 67: children: 6, perfumes: 7, cars: 3
|
||||||
|
Sue 68: goldfish: 8, cars: 6, children: 1
|
||||||
|
Sue 69: vizslas: 5, perfumes: 3, cars: 9
|
||||||
|
Sue 70: goldfish: 0, cats: 6, perfumes: 0
|
||||||
|
Sue 71: trees: 2, samoyeds: 3, cars: 1
|
||||||
|
Sue 72: cats: 3, akitas: 8, vizslas: 7
|
||||||
|
Sue 73: akitas: 3, vizslas: 2, goldfish: 6
|
||||||
|
Sue 74: pomeranians: 10, samoyeds: 9, cats: 8
|
||||||
|
Sue 75: vizslas: 7, cars: 7, akitas: 10
|
||||||
|
Sue 76: children: 3, cats: 6, vizslas: 3
|
||||||
|
Sue 77: goldfish: 7, pomeranians: 10, trees: 0
|
||||||
|
Sue 78: vizslas: 9, children: 7, trees: 10
|
||||||
|
Sue 79: trees: 6, pomeranians: 8, samoyeds: 1
|
||||||
|
Sue 80: vizslas: 5, children: 6, pomeranians: 5
|
||||||
|
Sue 81: cars: 9, vizslas: 9, akitas: 9
|
||||||
|
Sue 82: vizslas: 3, cars: 8, akitas: 1
|
||||||
|
Sue 83: vizslas: 4, trees: 2, cats: 1
|
||||||
|
Sue 84: children: 3, akitas: 0, vizslas: 1
|
||||||
|
Sue 85: cats: 6, vizslas: 5, akitas: 2
|
||||||
|
Sue 86: cars: 3, akitas: 7, goldfish: 8
|
||||||
|
Sue 87: samoyeds: 8, vizslas: 3, goldfish: 8
|
||||||
|
Sue 88: vizslas: 4, children: 0, cats: 7
|
||||||
|
Sue 89: goldfish: 9, pomeranians: 10, samoyeds: 0
|
||||||
|
Sue 90: trees: 6, akitas: 3, cars: 7
|
||||||
|
Sue 91: samoyeds: 3, akitas: 7, perfumes: 10
|
||||||
|
Sue 92: cars: 7, pomeranians: 10, trees: 2
|
||||||
|
Sue 93: samoyeds: 1, children: 3, cars: 3
|
||||||
|
Sue 94: samoyeds: 8, akitas: 7, vizslas: 0
|
||||||
|
Sue 95: goldfish: 7, children: 2, cars: 6
|
||||||
|
Sue 96: cars: 3, perfumes: 9, akitas: 10
|
||||||
|
Sue 97: akitas: 9, cars: 10, vizslas: 10
|
||||||
|
Sue 98: trees: 4, goldfish: 8, pomeranians: 7
|
||||||
|
Sue 99: samoyeds: 6, pomeranians: 0, vizslas: 7
|
||||||
|
Sue 100: akitas: 7, perfumes: 8, vizslas: 3
|
||||||
|
Sue 101: cars: 5, perfumes: 1, trees: 0
|
||||||
|
Sue 102: akitas: 6, pomeranians: 10, trees: 0
|
||||||
|
Sue 103: trees: 3, perfumes: 5, cats: 9
|
||||||
|
Sue 104: goldfish: 10, perfumes: 8, akitas: 0
|
||||||
|
Sue 105: goldfish: 6, vizslas: 5, trees: 2
|
||||||
|
Sue 106: pomeranians: 9, samoyeds: 10, perfumes: 10
|
||||||
|
Sue 107: cars: 8, vizslas: 4, akitas: 2
|
||||||
|
Sue 108: cats: 0, goldfish: 7, trees: 0
|
||||||
|
Sue 109: cars: 3, pomeranians: 6, trees: 2
|
||||||
|
Sue 110: perfumes: 4, goldfish: 5, akitas: 10
|
||||||
|
Sue 111: cars: 3, perfumes: 4, pomeranians: 4
|
||||||
|
Sue 112: cats: 2, goldfish: 10, akitas: 0
|
||||||
|
Sue 113: cats: 10, children: 0, trees: 1
|
||||||
|
Sue 114: akitas: 10, vizslas: 3, goldfish: 0
|
||||||
|
Sue 115: samoyeds: 3, goldfish: 6, vizslas: 1
|
||||||
|
Sue 116: cars: 3, perfumes: 5, trees: 6
|
||||||
|
Sue 117: akitas: 9, samoyeds: 8, goldfish: 8
|
||||||
|
Sue 118: pomeranians: 5, perfumes: 10, trees: 1
|
||||||
|
Sue 119: goldfish: 6, perfumes: 3, children: 1
|
||||||
|
Sue 120: trees: 1, children: 3, pomeranians: 6
|
||||||
|
Sue 121: akitas: 7, cars: 10, vizslas: 9
|
||||||
|
Sue 122: trees: 4, akitas: 8, samoyeds: 10
|
||||||
|
Sue 123: cats: 4, cars: 8, vizslas: 9
|
||||||
|
Sue 124: cars: 10, children: 1, trees: 0
|
||||||
|
Sue 125: goldfish: 5, pomeranians: 5, trees: 2
|
||||||
|
Sue 126: goldfish: 1, vizslas: 8, akitas: 10
|
||||||
|
Sue 127: vizslas: 4, cars: 9, akitas: 1
|
||||||
|
Sue 128: goldfish: 8, perfumes: 3, cars: 9
|
||||||
|
Sue 129: goldfish: 9, pomeranians: 9, perfumes: 1
|
||||||
|
Sue 130: trees: 1, vizslas: 9, perfumes: 3
|
||||||
|
Sue 131: children: 6, trees: 8, vizslas: 8
|
||||||
|
Sue 132: cars: 1, vizslas: 3, children: 7
|
||||||
|
Sue 133: cars: 7, children: 1, perfumes: 6
|
||||||
|
Sue 134: trees: 8, vizslas: 3, samoyeds: 2
|
||||||
|
Sue 135: cats: 9, perfumes: 4, pomeranians: 7
|
||||||
|
Sue 136: perfumes: 0, akitas: 8, vizslas: 6
|
||||||
|
Sue 137: goldfish: 5, trees: 0, vizslas: 7
|
||||||
|
Sue 138: trees: 1, perfumes: 2, cars: 10
|
||||||
|
Sue 139: samoyeds: 8, goldfish: 8, trees: 0
|
||||||
|
Sue 140: vizslas: 10, perfumes: 9, goldfish: 0
|
||||||
|
Sue 141: perfumes: 7, cars: 9, cats: 5
|
||||||
|
Sue 142: trees: 2, samoyeds: 2, cars: 0
|
||||||
|
Sue 143: cars: 1, perfumes: 1, akitas: 1
|
||||||
|
Sue 144: vizslas: 9, cars: 7, pomeranians: 10
|
||||||
|
Sue 145: pomeranians: 2, samoyeds: 7, children: 7
|
||||||
|
Sue 146: vizslas: 6, cars: 9, goldfish: 7
|
||||||
|
Sue 147: trees: 2, vizslas: 1, cats: 9
|
||||||
|
Sue 148: perfumes: 9, trees: 4, pomeranians: 5
|
||||||
|
Sue 149: samoyeds: 8, children: 1, vizslas: 9
|
||||||
|
Sue 150: cats: 3, trees: 2, vizslas: 4
|
||||||
|
Sue 151: goldfish: 7, akitas: 10, trees: 3
|
||||||
|
Sue 152: perfumes: 4, vizslas: 7, cars: 4
|
||||||
|
Sue 153: pomeranians: 4, akitas: 0, vizslas: 3
|
||||||
|
Sue 154: samoyeds: 8, trees: 2, vizslas: 10
|
||||||
|
Sue 155: vizslas: 7, cats: 7, pomeranians: 5
|
||||||
|
Sue 156: goldfish: 10, pomeranians: 1, vizslas: 1
|
||||||
|
Sue 157: cars: 6, perfumes: 7, trees: 9
|
||||||
|
Sue 158: trees: 5, samoyeds: 9, goldfish: 3
|
||||||
|
Sue 159: pomeranians: 4, akitas: 6, vizslas: 8
|
||||||
|
Sue 160: goldfish: 7, children: 0, cats: 0
|
||||||
|
Sue 161: vizslas: 5, akitas: 0, samoyeds: 2
|
||||||
|
Sue 162: akitas: 4, children: 0, vizslas: 3
|
||||||
|
Sue 163: samoyeds: 2, perfumes: 0, goldfish: 9
|
||||||
|
Sue 164: cars: 9, vizslas: 8, akitas: 6
|
||||||
|
Sue 165: samoyeds: 9, vizslas: 9, perfumes: 5
|
||||||
|
Sue 166: cars: 5, pomeranians: 4, samoyeds: 8
|
||||||
|
Sue 167: cars: 10, perfumes: 3, samoyeds: 6
|
||||||
|
Sue 168: pomeranians: 8, goldfish: 9, trees: 9
|
||||||
|
Sue 169: vizslas: 7, akitas: 3, samoyeds: 4
|
||||||
|
Sue 170: cats: 2, goldfish: 0, vizslas: 4
|
||||||
|
Sue 171: perfumes: 3, goldfish: 10, cats: 3
|
||||||
|
Sue 172: goldfish: 7, akitas: 6, cars: 0
|
||||||
|
Sue 173: cars: 9, goldfish: 7, akitas: 5
|
||||||
|
Sue 174: goldfish: 6, cats: 0, vizslas: 8
|
||||||
|
Sue 175: perfumes: 7, cats: 10, cars: 10
|
||||||
|
Sue 176: samoyeds: 9, vizslas: 4, pomeranians: 10
|
||||||
|
Sue 177: perfumes: 0, trees: 0, cars: 10
|
||||||
|
Sue 178: vizslas: 6, children: 7, samoyeds: 1
|
||||||
|
Sue 179: vizslas: 8, children: 6, trees: 0
|
||||||
|
Sue 180: cars: 1, vizslas: 6, trees: 1
|
||||||
|
Sue 181: vizslas: 10, perfumes: 3, cars: 1
|
||||||
|
Sue 182: trees: 8, samoyeds: 9, cars: 7
|
||||||
|
Sue 183: cars: 6, vizslas: 2, perfumes: 7
|
||||||
|
Sue 184: trees: 5, samoyeds: 9, akitas: 0
|
||||||
|
Sue 185: cars: 8, goldfish: 8, trees: 4
|
||||||
|
Sue 186: samoyeds: 6, goldfish: 1, trees: 2
|
||||||
|
Sue 187: perfumes: 1, trees: 2, akitas: 7
|
||||||
|
Sue 188: samoyeds: 5, cars: 6, perfumes: 2
|
||||||
|
Sue 189: samoyeds: 8, goldfish: 3, perfumes: 5
|
||||||
|
Sue 190: akitas: 2, cats: 1, samoyeds: 1
|
||||||
|
Sue 191: trees: 5, akitas: 1, goldfish: 7
|
||||||
|
Sue 192: vizslas: 3, trees: 0, perfumes: 4
|
||||||
|
Sue 193: cars: 3, perfumes: 4, akitas: 3
|
||||||
|
Sue 194: perfumes: 4, vizslas: 8, children: 4
|
||||||
|
Sue 195: vizslas: 1, samoyeds: 3, cars: 6
|
||||||
|
Sue 196: cars: 5, perfumes: 6, vizslas: 2
|
||||||
|
Sue 197: vizslas: 8, akitas: 8, cats: 6
|
||||||
|
Sue 198: cars: 9, akitas: 2, pomeranians: 7
|
||||||
|
Sue 199: cats: 9, akitas: 6, cars: 10
|
||||||
|
Sue 200: vizslas: 10, pomeranians: 2, goldfish: 9
|
||||||
|
Sue 201: vizslas: 9, samoyeds: 4, akitas: 3
|
||||||
|
Sue 202: akitas: 5, cats: 2, vizslas: 0
|
||||||
|
Sue 203: perfumes: 1, children: 3, akitas: 10
|
||||||
|
Sue 204: trees: 4, vizslas: 7, akitas: 9
|
||||||
|
Sue 205: trees: 8, perfumes: 9, cars: 1
|
||||||
|
Sue 206: goldfish: 6, trees: 5, cars: 8
|
||||||
|
Sue 207: akitas: 3, vizslas: 8, trees: 8
|
||||||
|
Sue 208: vizslas: 4, perfumes: 7, akitas: 10
|
||||||
|
Sue 209: cars: 9, perfumes: 7, goldfish: 9
|
||||||
|
Sue 210: vizslas: 2, cats: 2, akitas: 10
|
||||||
|
Sue 211: akitas: 1, trees: 3, cars: 2
|
||||||
|
Sue 212: goldfish: 5, trees: 0, vizslas: 7
|
||||||
|
Sue 213: akitas: 3, perfumes: 1, vizslas: 5
|
||||||
|
Sue 214: perfumes: 3, pomeranians: 6, cars: 0
|
||||||
|
Sue 215: goldfish: 1, cats: 9, cars: 3
|
||||||
|
Sue 216: goldfish: 9, pomeranians: 6, samoyeds: 0
|
||||||
|
Sue 217: cars: 6, trees: 2, perfumes: 2
|
||||||
|
Sue 218: vizslas: 3, goldfish: 8, akitas: 5
|
||||||
|
Sue 219: cats: 9, perfumes: 7, cars: 5
|
||||||
|
Sue 220: pomeranians: 5, vizslas: 4, cats: 5
|
||||||
|
Sue 221: trees: 0, akitas: 7, goldfish: 10
|
||||||
|
Sue 222: akitas: 2, cars: 3, vizslas: 5
|
||||||
|
Sue 223: goldfish: 3, perfumes: 7, akitas: 4
|
||||||
|
Sue 224: samoyeds: 2, cars: 4, vizslas: 7
|
||||||
|
Sue 225: trees: 5, cars: 0, perfumes: 0
|
||||||
|
Sue 226: trees: 2, goldfish: 10, perfumes: 6
|
||||||
|
Sue 227: cars: 8, trees: 9, akitas: 6
|
||||||
|
Sue 228: goldfish: 10, trees: 10, perfumes: 0
|
||||||
|
Sue 229: children: 7, samoyeds: 4, goldfish: 6
|
||||||
|
Sue 230: vizslas: 9, perfumes: 1, children: 10
|
||||||
|
Sue 231: vizslas: 8, trees: 5, akitas: 9
|
||||||
|
Sue 232: akitas: 5, goldfish: 9, trees: 1
|
||||||
|
Sue 233: vizslas: 3, trees: 2, children: 9
|
||||||
|
Sue 234: samoyeds: 8, perfumes: 0, cats: 0
|
||||||
|
Sue 235: perfumes: 4, vizslas: 3, akitas: 5
|
||||||
|
Sue 236: pomeranians: 5, vizslas: 3, akitas: 9
|
||||||
|
Sue 237: cats: 1, trees: 7, vizslas: 5
|
||||||
|
Sue 238: children: 5, cats: 4, samoyeds: 5
|
||||||
|
Sue 239: trees: 3, akitas: 2, goldfish: 6
|
||||||
|
Sue 240: goldfish: 9, trees: 1, perfumes: 1
|
||||||
|
Sue 241: cars: 2, pomeranians: 1, samoyeds: 2
|
||||||
|
Sue 242: akitas: 2, trees: 3, cars: 4
|
||||||
|
Sue 243: vizslas: 6, akitas: 2, samoyeds: 7
|
||||||
|
Sue 244: trees: 0, perfumes: 5, cars: 7
|
||||||
|
Sue 245: goldfish: 10, perfumes: 5, vizslas: 8
|
||||||
|
Sue 246: akitas: 0, perfumes: 0, cars: 1
|
||||||
|
Sue 247: samoyeds: 8, goldfish: 0, cars: 6
|
||||||
|
Sue 248: perfumes: 0, children: 10, trees: 10
|
||||||
|
Sue 249: perfumes: 6, akitas: 5, cats: 5
|
||||||
|
Sue 250: vizslas: 7, akitas: 4, cats: 5
|
||||||
|
Sue 251: samoyeds: 4, akitas: 1, trees: 8
|
||||||
|
Sue 252: perfumes: 8, pomeranians: 5, cars: 1
|
||||||
|
Sue 253: akitas: 10, trees: 4, cats: 3
|
||||||
|
Sue 254: perfumes: 2, cats: 2, goldfish: 9
|
||||||
|
Sue 255: cars: 4, trees: 1, akitas: 4
|
||||||
|
Sue 256: samoyeds: 9, goldfish: 0, akitas: 9
|
||||||
|
Sue 257: vizslas: 9, perfumes: 2, goldfish: 2
|
||||||
|
Sue 258: perfumes: 1, cars: 9, samoyeds: 1
|
||||||
|
Sue 259: trees: 0, goldfish: 0, samoyeds: 3
|
||||||
|
Sue 260: perfumes: 7, cars: 1, goldfish: 0
|
||||||
|
Sue 261: cars: 0, trees: 5, goldfish: 6
|
||||||
|
Sue 262: akitas: 7, vizslas: 3, pomeranians: 5
|
||||||
|
Sue 263: trees: 1, vizslas: 3, goldfish: 3
|
||||||
|
Sue 264: akitas: 7, vizslas: 4, children: 0
|
||||||
|
Sue 265: samoyeds: 5, trees: 0, akitas: 4
|
||||||
|
Sue 266: perfumes: 9, goldfish: 9, cars: 8
|
||||||
|
Sue 267: cars: 7, perfumes: 10, pomeranians: 8
|
||||||
|
Sue 268: cars: 0, akitas: 7, perfumes: 4
|
||||||
|
Sue 269: pomeranians: 0, cars: 9, perfumes: 10
|
||||||
|
Sue 270: samoyeds: 10, perfumes: 10, cars: 9
|
||||||
|
Sue 271: akitas: 2, vizslas: 8, cats: 5
|
||||||
|
Sue 272: akitas: 3, children: 9, samoyeds: 10
|
||||||
|
Sue 273: perfumes: 2, cars: 10, goldfish: 8
|
||||||
|
Sue 274: cars: 3, children: 10, perfumes: 10
|
||||||
|
Sue 275: cats: 9, akitas: 5, trees: 0
|
||||||
|
Sue 276: akitas: 6, children: 2, vizslas: 1
|
||||||
|
Sue 277: pomeranians: 6, trees: 10, samoyeds: 3
|
||||||
|
Sue 278: cars: 7, perfumes: 10, trees: 1
|
||||||
|
Sue 279: cars: 6, pomeranians: 8, trees: 2
|
||||||
|
Sue 280: pomeranians: 9, cats: 0, perfumes: 7
|
||||||
|
Sue 281: vizslas: 10, goldfish: 9, pomeranians: 5
|
||||||
|
Sue 282: perfumes: 4, samoyeds: 7, cars: 9
|
||||||
|
Sue 283: cars: 9, vizslas: 6, trees: 5
|
||||||
|
Sue 284: cars: 7, trees: 1, vizslas: 4
|
||||||
|
Sue 285: samoyeds: 4, goldfish: 10, cats: 4
|
||||||
|
Sue 286: samoyeds: 0, akitas: 4, children: 5
|
||||||
|
Sue 287: trees: 1, perfumes: 3, goldfish: 10
|
||||||
|
Sue 288: pomeranians: 10, akitas: 3, cars: 2
|
||||||
|
Sue 289: trees: 7, pomeranians: 4, goldfish: 10
|
||||||
|
Sue 290: samoyeds: 10, perfumes: 0, cars: 9
|
||||||
|
Sue 291: akitas: 0, pomeranians: 7, vizslas: 4
|
||||||
|
Sue 292: cats: 2, vizslas: 8, goldfish: 5
|
||||||
|
Sue 293: vizslas: 6, pomeranians: 9, perfumes: 0
|
||||||
|
Sue 294: akitas: 6, cars: 7, vizslas: 5
|
||||||
|
Sue 295: goldfish: 0, akitas: 9, cats: 0
|
||||||
|
Sue 296: goldfish: 1, trees: 0, cars: 6
|
||||||
|
Sue 297: perfumes: 6, cats: 8, pomeranians: 6
|
||||||
|
Sue 298: cats: 0, goldfish: 6, perfumes: 2
|
||||||
|
Sue 299: cars: 4, akitas: 1, samoyeds: 10
|
||||||
|
Sue 300: goldfish: 9, samoyeds: 6, cats: 5
|
||||||
|
Sue 301: cars: 0, vizslas: 7, trees: 0
|
||||||
|
Sue 302: goldfish: 9, samoyeds: 1, children: 6
|
||||||
|
Sue 303: cars: 6, perfumes: 7, samoyeds: 8
|
||||||
|
Sue 304: trees: 8, goldfish: 9, children: 9
|
||||||
|
Sue 305: perfumes: 0, cars: 5, goldfish: 4
|
||||||
|
Sue 306: cats: 3, cars: 7, vizslas: 7
|
||||||
|
Sue 307: pomeranians: 4, perfumes: 6, cars: 2
|
||||||
|
Sue 308: cars: 9, akitas: 6, goldfish: 4
|
||||||
|
Sue 309: pomeranians: 2, vizslas: 10, goldfish: 10
|
||||||
|
Sue 310: children: 0, cats: 4, akitas: 7
|
||||||
|
Sue 311: children: 10, akitas: 8, vizslas: 2
|
||||||
|
Sue 312: children: 5, cars: 0, vizslas: 4
|
||||||
|
Sue 313: perfumes: 10, trees: 3, pomeranians: 9
|
||||||
|
Sue 314: samoyeds: 3, goldfish: 2, trees: 9
|
||||||
|
Sue 315: cars: 2, cats: 5, pomeranians: 10
|
||||||
|
Sue 316: cats: 6, pomeranians: 6, children: 9
|
||||||
|
Sue 317: cats: 2, vizslas: 3, perfumes: 1
|
||||||
|
Sue 318: akitas: 1, perfumes: 3, vizslas: 10
|
||||||
|
Sue 319: cars: 7, perfumes: 0, trees: 0
|
||||||
|
Sue 320: goldfish: 6, samoyeds: 6, pomeranians: 4
|
||||||
|
Sue 321: trees: 2, goldfish: 6, children: 0
|
||||||
|
Sue 322: goldfish: 0, trees: 2, akitas: 8
|
||||||
|
Sue 323: pomeranians: 2, samoyeds: 9, vizslas: 1
|
||||||
|
Sue 324: trees: 4, goldfish: 6, pomeranians: 6
|
||||||
|
Sue 325: trees: 2, pomeranians: 3, goldfish: 1
|
||||||
|
Sue 326: perfumes: 4, goldfish: 6, trees: 5
|
||||||
|
Sue 327: akitas: 3, cars: 8, cats: 2
|
||||||
|
Sue 328: cats: 6, vizslas: 0, akitas: 2
|
||||||
|
Sue 329: perfumes: 3, goldfish: 10, akitas: 3
|
||||||
|
Sue 330: goldfish: 3, vizslas: 1, akitas: 6
|
||||||
|
Sue 331: perfumes: 4, trees: 1, goldfish: 5
|
||||||
|
Sue 332: goldfish: 7, vizslas: 9, akitas: 1
|
||||||
|
Sue 333: children: 8, cars: 8, trees: 4
|
||||||
|
Sue 334: cars: 1, vizslas: 6, trees: 0
|
||||||
|
Sue 335: goldfish: 2, cars: 2, akitas: 1
|
||||||
|
Sue 336: goldfish: 5, akitas: 5, trees: 9
|
||||||
|
Sue 337: cars: 5, vizslas: 6, goldfish: 6
|
||||||
|
Sue 338: cats: 9, akitas: 3, goldfish: 9
|
||||||
|
Sue 339: akitas: 3, cats: 2, children: 7
|
||||||
|
Sue 340: goldfish: 0, pomeranians: 8, perfumes: 9
|
||||||
|
Sue 341: trees: 0, pomeranians: 1, goldfish: 5
|
||||||
|
Sue 342: goldfish: 10, trees: 3, vizslas: 4
|
||||||
|
Sue 343: cats: 3, samoyeds: 1, children: 6
|
||||||
|
Sue 344: perfumes: 3, children: 4, samoyeds: 2
|
||||||
|
Sue 345: children: 6, trees: 2, goldfish: 1
|
||||||
|
Sue 346: trees: 2, pomeranians: 3, goldfish: 5
|
||||||
|
Sue 347: akitas: 10, vizslas: 7, trees: 1
|
||||||
|
Sue 348: perfumes: 4, akitas: 2, vizslas: 7
|
||||||
|
Sue 349: perfumes: 8, goldfish: 3, vizslas: 5
|
||||||
|
Sue 350: trees: 4, pomeranians: 5, akitas: 10
|
||||||
|
Sue 351: perfumes: 5, cars: 9, trees: 0
|
||||||
|
Sue 352: akitas: 6, children: 8, trees: 10
|
||||||
|
Sue 353: samoyeds: 7, akitas: 6, vizslas: 4
|
||||||
|
Sue 354: children: 9, goldfish: 7, perfumes: 5
|
||||||
|
Sue 355: trees: 1, perfumes: 4, cars: 1
|
||||||
|
Sue 356: samoyeds: 1, perfumes: 4, pomeranians: 8
|
||||||
|
Sue 357: trees: 7, goldfish: 10, akitas: 0
|
||||||
|
Sue 358: akitas: 1, vizslas: 6, cars: 7
|
||||||
|
Sue 359: vizslas: 3, goldfish: 8, trees: 4
|
||||||
|
Sue 360: akitas: 10, vizslas: 2, trees: 3
|
||||||
|
Sue 361: samoyeds: 6, pomeranians: 1, perfumes: 0
|
||||||
|
Sue 362: samoyeds: 3, cars: 1, trees: 0
|
||||||
|
Sue 363: vizslas: 0, pomeranians: 9, akitas: 4
|
||||||
|
Sue 364: perfumes: 9, pomeranians: 8, vizslas: 9
|
||||||
|
Sue 365: vizslas: 7, cars: 4, perfumes: 10
|
||||||
|
Sue 366: cars: 0, samoyeds: 5, goldfish: 10
|
||||||
|
Sue 367: children: 4, vizslas: 5, akitas: 4
|
||||||
|
Sue 368: samoyeds: 9, perfumes: 4, vizslas: 6
|
||||||
|
Sue 369: perfumes: 5, cars: 4, samoyeds: 5
|
||||||
|
Sue 370: akitas: 3, vizslas: 2, perfumes: 1
|
||||||
|
Sue 371: cars: 8, cats: 7, children: 5
|
||||||
|
Sue 372: vizslas: 9, perfumes: 2, akitas: 10
|
||||||
|
Sue 373: trees: 10, pomeranians: 9, goldfish: 3
|
||||||
|
Sue 374: children: 4, cars: 10, perfumes: 2
|
||||||
|
Sue 375: children: 7, samoyeds: 5, cats: 0
|
||||||
|
Sue 376: akitas: 10, samoyeds: 5, vizslas: 5
|
||||||
|
Sue 377: goldfish: 8, trees: 3, perfumes: 3
|
||||||
|
Sue 378: goldfish: 10, vizslas: 0, perfumes: 2
|
||||||
|
Sue 379: trees: 1, vizslas: 7, pomeranians: 4
|
||||||
|
Sue 380: samoyeds: 8, vizslas: 3, trees: 2
|
||||||
|
Sue 381: goldfish: 2, perfumes: 5, samoyeds: 9
|
||||||
|
Sue 382: cats: 3, vizslas: 10, akitas: 5
|
||||||
|
Sue 383: cars: 7, goldfish: 5, akitas: 8
|
||||||
|
Sue 384: children: 6, goldfish: 10, trees: 1
|
||||||
|
Sue 385: cats: 2, akitas: 6, samoyeds: 7
|
||||||
|
Sue 386: cars: 10, children: 4, goldfish: 2
|
||||||
|
Sue 387: cats: 0, perfumes: 5, akitas: 9
|
||||||
|
Sue 388: pomeranians: 7, akitas: 0, samoyeds: 9
|
||||||
|
Sue 389: trees: 0, akitas: 9, vizslas: 8
|
||||||
|
Sue 390: cars: 0, trees: 10, perfumes: 9
|
||||||
|
Sue 391: cats: 9, goldfish: 10, perfumes: 10
|
||||||
|
Sue 392: cars: 3, vizslas: 6, cats: 3
|
||||||
|
Sue 393: vizslas: 10, perfumes: 4, goldfish: 5
|
||||||
|
Sue 394: perfumes: 4, akitas: 10, trees: 2
|
||||||
|
Sue 395: pomeranians: 5, cars: 4, perfumes: 3
|
||||||
|
Sue 396: pomeranians: 9, vizslas: 5, akitas: 2
|
||||||
|
Sue 397: cars: 10, goldfish: 8, trees: 2
|
||||||
|
Sue 398: perfumes: 7, children: 9, goldfish: 9
|
||||||
|
Sue 399: akitas: 6, cats: 2, goldfish: 7
|
||||||
|
Sue 400: goldfish: 9, perfumes: 0, cars: 2
|
||||||
|
Sue 401: children: 4, vizslas: 0, trees: 2
|
||||||
|
Sue 402: akitas: 4, cars: 8, pomeranians: 4
|
||||||
|
Sue 403: vizslas: 8, perfumes: 7, goldfish: 1
|
||||||
|
Sue 404: goldfish: 10, samoyeds: 7, vizslas: 3
|
||||||
|
Sue 405: akitas: 1, vizslas: 6, perfumes: 6
|
||||||
|
Sue 406: pomeranians: 8, goldfish: 6, cats: 3
|
||||||
|
Sue 407: goldfish: 2, vizslas: 4, akitas: 7
|
||||||
|
Sue 408: cars: 10, perfumes: 10, vizslas: 3
|
||||||
|
Sue 409: vizslas: 7, pomeranians: 4, perfumes: 4
|
||||||
|
Sue 410: goldfish: 4, vizslas: 7, trees: 5
|
||||||
|
Sue 411: cars: 8, trees: 0, goldfish: 4
|
||||||
|
Sue 412: cars: 8, perfumes: 5, vizslas: 4
|
||||||
|
Sue 413: vizslas: 3, akitas: 7, samoyeds: 6
|
||||||
|
Sue 414: trees: 0, perfumes: 6, cars: 10
|
||||||
|
Sue 415: pomeranians: 4, trees: 1, perfumes: 6
|
||||||
|
Sue 416: cars: 10, perfumes: 6, akitas: 2
|
||||||
|
Sue 417: perfumes: 6, samoyeds: 0, akitas: 0
|
||||||
|
Sue 418: children: 1, perfumes: 9, vizslas: 3
|
||||||
|
Sue 419: goldfish: 9, samoyeds: 3, perfumes: 8
|
||||||
|
Sue 420: goldfish: 4, cars: 10, vizslas: 7
|
||||||
|
Sue 421: samoyeds: 7, vizslas: 7, cats: 2
|
||||||
|
Sue 422: trees: 1, goldfish: 8, perfumes: 0
|
||||||
|
Sue 423: cars: 3, perfumes: 2, trees: 3
|
||||||
|
Sue 424: samoyeds: 6, vizslas: 0, akitas: 6
|
||||||
|
Sue 425: trees: 3, akitas: 7, goldfish: 1
|
||||||
|
Sue 426: cars: 9, trees: 1, perfumes: 0
|
||||||
|
Sue 427: pomeranians: 0, children: 5, perfumes: 8
|
||||||
|
Sue 428: cars: 0, perfumes: 6, children: 4
|
||||||
|
Sue 429: akitas: 7, pomeranians: 9, cats: 6
|
||||||
|
Sue 430: cats: 6, trees: 1, cars: 0
|
||||||
|
Sue 431: children: 8, akitas: 5, perfumes: 9
|
||||||
|
Sue 432: perfumes: 5, akitas: 10, trees: 9
|
||||||
|
Sue 433: akitas: 4, perfumes: 10, vizslas: 7
|
||||||
|
Sue 434: trees: 3, children: 10, samoyeds: 4
|
||||||
|
Sue 435: vizslas: 5, goldfish: 2, akitas: 2
|
||||||
|
Sue 436: samoyeds: 3, trees: 2, cars: 6
|
||||||
|
Sue 437: children: 9, akitas: 0, pomeranians: 3
|
||||||
|
Sue 438: perfumes: 10, akitas: 2, cars: 7
|
||||||
|
Sue 439: perfumes: 10, samoyeds: 6, akitas: 10
|
||||||
|
Sue 440: vizslas: 10, trees: 2, akitas: 8
|
||||||
|
Sue 441: perfumes: 8, akitas: 2, pomeranians: 7
|
||||||
|
Sue 442: cars: 8, trees: 3, goldfish: 6
|
||||||
|
Sue 443: cars: 1, goldfish: 5, vizslas: 5
|
||||||
|
Sue 444: vizslas: 2, akitas: 10, samoyeds: 4
|
||||||
|
Sue 445: vizslas: 2, akitas: 10, perfumes: 9
|
||||||
|
Sue 446: akitas: 3, vizslas: 8, goldfish: 1
|
||||||
|
Sue 447: vizslas: 7, pomeranians: 5, trees: 10
|
||||||
|
Sue 448: cats: 6, perfumes: 10, children: 6
|
||||||
|
Sue 449: trees: 2, cars: 5, goldfish: 8
|
||||||
|
Sue 450: trees: 0, goldfish: 6, samoyeds: 3
|
||||||
|
Sue 451: perfumes: 0, cars: 8, trees: 1
|
||||||
|
Sue 452: akitas: 4, trees: 8, perfumes: 9
|
||||||
|
Sue 453: goldfish: 1, perfumes: 7, akitas: 6
|
||||||
|
Sue 454: vizslas: 3, cars: 1, perfumes: 6
|
||||||
|
Sue 455: trees: 1, akitas: 7, goldfish: 10
|
||||||
|
Sue 456: samoyeds: 4, vizslas: 2, cars: 9
|
||||||
|
Sue 457: perfumes: 10, children: 1, trees: 8
|
||||||
|
Sue 458: perfumes: 0, vizslas: 9, cars: 8
|
||||||
|
Sue 459: cats: 0, children: 7, trees: 3
|
||||||
|
Sue 460: vizslas: 4, cats: 6, perfumes: 2
|
||||||
|
Sue 461: trees: 3, children: 5, cars: 8
|
||||||
|
Sue 462: goldfish: 7, vizslas: 7, children: 5
|
||||||
|
Sue 463: cars: 5, akitas: 3, goldfish: 5
|
||||||
|
Sue 464: vizslas: 0, pomeranians: 5, cars: 0
|
||||||
|
Sue 465: goldfish: 4, akitas: 0, cats: 5
|
||||||
|
Sue 466: cars: 5, trees: 1, goldfish: 6
|
||||||
|
Sue 467: perfumes: 10, trees: 8, cars: 1
|
||||||
|
Sue 468: perfumes: 4, akitas: 3, cars: 0
|
||||||
|
Sue 469: vizslas: 3, cars: 7, pomeranians: 1
|
||||||
|
Sue 470: perfumes: 1, vizslas: 7, akitas: 8
|
||||||
|
Sue 471: goldfish: 10, samoyeds: 10, pomeranians: 5
|
||||||
|
Sue 472: goldfish: 6, trees: 0, perfumes: 0
|
||||||
|
Sue 473: goldfish: 5, vizslas: 0, children: 5
|
||||||
|
Sue 474: cars: 3, vizslas: 7, perfumes: 10
|
||||||
|
Sue 475: vizslas: 5, trees: 9, goldfish: 8
|
||||||
|
Sue 476: akitas: 2, goldfish: 6, children: 7
|
||||||
|
Sue 477: samoyeds: 0, perfumes: 1, pomeranians: 5
|
||||||
|
Sue 478: trees: 2, goldfish: 9, vizslas: 0
|
||||||
|
Sue 479: perfumes: 1, cars: 6, goldfish: 9
|
||||||
|
Sue 480: pomeranians: 3, perfumes: 5, trees: 9
|
||||||
|
Sue 481: cats: 3, akitas: 0, vizslas: 8
|
||||||
|
Sue 482: pomeranians: 10, akitas: 8, trees: 5
|
||||||
|
Sue 483: goldfish: 6, akitas: 10, perfumes: 2
|
||||||
|
Sue 484: cats: 0, goldfish: 0, children: 9
|
||||||
|
Sue 485: children: 4, akitas: 10, vizslas: 8
|
||||||
|
Sue 486: vizslas: 3, goldfish: 9, children: 10
|
||||||
|
Sue 487: children: 8, cats: 6, vizslas: 10
|
||||||
|
Sue 488: cars: 7, akitas: 10, samoyeds: 5
|
||||||
|
Sue 489: vizslas: 9, akitas: 6, trees: 2
|
||||||
|
Sue 490: vizslas: 5, akitas: 1, children: 5
|
||||||
|
Sue 491: vizslas: 8, goldfish: 3, perfumes: 6
|
||||||
|
Sue 492: trees: 3, samoyeds: 1, pomeranians: 6
|
||||||
|
Sue 493: akitas: 1, vizslas: 5, cars: 8
|
||||||
|
Sue 494: akitas: 4, cars: 4, vizslas: 9
|
||||||
|
Sue 495: vizslas: 1, akitas: 2, cats: 2
|
||||||
|
Sue 496: trees: 7, vizslas: 5, akitas: 6
|
||||||
|
Sue 497: akitas: 8, trees: 2, perfumes: 6
|
||||||
|
Sue 498: akitas: 1, trees: 1, samoyeds: 4
|
||||||
|
Sue 499: cars: 0, akitas: 5, vizslas: 3
|
||||||
|
Sue 500: cats: 2, goldfish: 9, children: 8
|
20
y2015/resources/17_input.txt
Normal file
20
y2015/resources/17_input.txt
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
11
|
||||||
|
30
|
||||||
|
47
|
||||||
|
31
|
||||||
|
32
|
||||||
|
36
|
||||||
|
3
|
||||||
|
1
|
||||||
|
5
|
||||||
|
3
|
||||||
|
32
|
||||||
|
36
|
||||||
|
15
|
||||||
|
11
|
||||||
|
46
|
||||||
|
26
|
||||||
|
28
|
||||||
|
1
|
||||||
|
19
|
||||||
|
3
|
100
y2015/resources/18_input.txt
Normal file
100
y2015/resources/18_input.txt
Normal file
@@ -0,0 +1,100 @@
|
|||||||
|
#..####.##..#...#..#...#...###.#.#.#..#....#.##..#...##...#..#.....##..#####....#.##..##....##.#....
|
||||||
|
.#..#..#..#.###...##..#.##.....#...#..##....#####.##............####.#..######..#.#.##.#...#..#...##
|
||||||
|
#.....##.##.##.#..##.#..###...#.#.#..##..###.####.####.#.####.#...##.#..###.........#.###...#....###
|
||||||
|
#.###..#######..##..#.....##.#.#.###.#.##..#.##..##.##.#.##...###.#...#.#####.#.##..#.#####..#.#####
|
||||||
|
#.##.##.###.##..###.#.##.##...##.#.#..##..###.########.#.####..####...#####...#..#...##....##.##.##.
|
||||||
|
..#.#.#.#..#.#.###....###...#...#.##..####.###.....#.####.###.###.#......#.#.###..#..#.#....#.#####.
|
||||||
|
...#.###.#....#.###...#.#.#...#...#.#####....#....#...#####..#..#.#..######..#.##.#.##.#..###.#...##
|
||||||
|
.###...#...#.#..#.#.####.#...#.....##...###.#....#..##.###....#.##....###..#.#####...###.#.##.####..
|
||||||
|
#.#....##.#.....#####.#.##..#######.#.####..###.##.#####.##.#...###...#.#...###..#...#.#.###.###.###
|
||||||
|
...##.##.....##..#.##...#.#...#...#.#####.#...#.#.#.#####.##.#...#.#..##.##..#...#....####..###.###.
|
||||||
|
#..#....######...#...###.#....#####....#.#.#....#....#.#######.#####..#....#....#.##..#.##.###..#...
|
||||||
|
#####.#.######.#.#####.#..##..##..####..#....#...#######....##..##.#..###..###.###..###...#...######
|
||||||
|
#...##..##...###....##..##.##..#.#.#.#....##.#.......###..###..###...###..##.##.##.#.#.#..#.#..#..#.
|
||||||
|
..###....##.###..#.#..########...###...##..#######....##..###..#####.##.#....###..##.##.##.#...##.#.
|
||||||
|
###..#.#..#.#.##.##...##.....#..###.#..##.##.#....##.#.######..##..#.#.##.###...#..####...#.#..#.###
|
||||||
|
.######....#..##..#.####.##..#.#..#.#..#....#..##.#..#.#...####..#....#.####.#.###.#...####.#...#.#.
|
||||||
|
#.######.##..###.###..#..###.#...#..#...#...###.##....#.#......#...#.##.#.###..#.#####.#.#..###..#.#
|
||||||
|
...#..#...####..###.########.....###.###.#..##.##....######..#..#.....#.##.##.#..##..#..##...#..#..#
|
||||||
|
#..#..##..#.#.########.##.#.####..#.#####.#.###.##....###..##..#.#.###..#.##..##.##.####...######.##
|
||||||
|
.######.###....#...##...#..#....##..#.#...###.######.##...#....##.##.#.#.##..#...###.###.#....#..##.
|
||||||
|
####.#.##..##.##.###...#.###.##..##....###..####.##..#.#.##..###.#..##...####...#..####.#.#..##...#.
|
||||||
|
.#.#..#.....##...#..#...#.#...#.#.##..#....#..#......#####.#######....#.#..#..###..##.#.########..##
|
||||||
|
.##.#..#..##..#..####.#...####...#...#..##.#..###.#..######..#.#...###.##...#..#####..##.#..##.#.##.
|
||||||
|
.###..##.##.##....###.###..#.#...##.#.#...#.#######.####..#..###.#######.#...#.#...#.##...#..####..#
|
||||||
|
##.########..#..#....#.###..##.##.#.##.#..#......####..##.##.#..####..#####..#.....#####.###..#.#.#.
|
||||||
|
.#..####..##.#.#..#####.##..#..#.#....#.#####.#####...######........##.##..##.#.#.###..#.#.#.#..##.#
|
||||||
|
.##..##..#.######..###....#.#.###.#........#..###..#.########.....#.##...#.....#..#...##...#..#.###.
|
||||||
|
##.##.#..####....####.#######.....#.#.#...#.######.#.....####.####...###..####.##.##....###..#..#...
|
||||||
|
#.#..####...#......#...###...##....##.#######..#.###.#...###.##.##...####..#.####..#......##..#####.
|
||||||
|
.#.#...##...#....#.####.##.....#....#.#.#######..###.#.....#.....####...##...#.#.##.####..##.###.#.#
|
||||||
|
####.#.#.####...#...####.#.....#.#######.#.......####......###..###.#...######..#.##.#.##..#..##..##
|
||||||
|
..##.###..#..####..####.......######.##..#.....##.##...##.##......#.###..###...#.##.#####.#.######.#
|
||||||
|
.###..####.###..#..#.......#.##...##...##.######.....#..####.#......#.#...#...#...###...#.#.##..####
|
||||||
|
.####....##.##.#.....##.###.####.#.......#.......#.#..#.#.#.....###.#.#####.#..#.#.#####.#####.###.#
|
||||||
|
.##.#.###.#####..#..#....###.#.#.#..#..###..##..####..##.###....#..####.####.#..###.#..######.######
|
||||||
|
####.#.....##..###....#.....#.##.#.##..##..########.#####..###.####....##.....######.#.#.##.......#.
|
||||||
|
#.#.##.....#.....##.###.#..#.##.##....#..##....##.#.###.##.#..#..##.##.###.#..##.###...##..###.#####
|
||||||
|
#.###.#.#.#.#.#.#.#...#..#.###..####.##...#..####.###....#..#..##.#....####..##.##....#.#.##.##....#
|
||||||
|
...######....#..####...#.#..#.#.#..#.##.#.#.......#..#......##..#...#..#..##...##.#...#.#.#...##.##.
|
||||||
|
.#####..#...####....#..###..##....#####..###.#.#...###..###.###..##...#......#...#...#.#.#...#.##..#
|
||||||
|
......#####.#...#.#.#.##..#.###..##..#.#...###..###....##..#####..#######.#..#.###....###...##.#..#.
|
||||||
|
..##.########.##..#....##.#...##.##.#.#..#.##..#.#.#.##....#.#.#.#.##....##....#....#####.##..#.##.#
|
||||||
|
####...#....##.#.###......##.##.#..##...#..#####..#.#....##..#####...#.#.##...#.####.####..##.######
|
||||||
|
.##.###.##.#...#.#....###.#######...##...##..#..##.###.#.####..#..###......#.#.##.#.#....#..##...#..
|
||||||
|
.#.###.#.###.###.#.##.#..#......####.##...#..##.#..####.....#...#.###.##.##.#..#.##..#.###......#..#
|
||||||
|
...##.####......#.#.#..###..#....###....#.##.#####..#..#..#...#.#.###...#.#.#.##....###.####..###.#.
|
||||||
|
##..#.#.#.#....####...#.##.###..####....#..#####.######..#.##.##..#####.#.....#.#...##.#.##.##.#.#..
|
||||||
|
#..##.#.#.#.###.#.#.###...#.#...##..#..#.#.#.##..###...#..##.#..#.#.#..#.....#.######.#.###..###.#..
|
||||||
|
....#.#.##.###.##...#.##.#....#..##.#..##...#...#.##.####...##..####.#.........#..##..#...#...##.#..
|
||||||
|
.##.......##...###.##.#.##.###.##.#..#..#..####...#...#....#####...###..##..#..#..##...#....#..#####
|
||||||
|
..####..#...#...#..###....##.#.#####..#..#.....#......#...#.......##....####...##....##.##.#.#####.#
|
||||||
|
##.#.#.#..##..##..#.####.##.##.###.#...###.#....#.....#.###...#######..###.####.###.####.##...##.#..
|
||||||
|
..#.#...##.#....#..#..##.####.....#.#.#...#..#..###.#..###.#####.#.#####.#.#.#.#.###.##.###..#....##
|
||||||
|
.###.#...#....###..#...####....####..#.##..#..##.###..#.#.#.#..#...###.#.#...#......#...#.##.##.#...
|
||||||
|
..####.####.##.#.##....#...##....#..#....#..###..#...#..###.#####.....#####..##.#.#.#.#.#.##.####...
|
||||||
|
...##.#.##.####..##.###..#.#.#.#.#.#.#..###...#.##..#.####.##...#.#.##......###..#...###....#.#.###.
|
||||||
|
##...##..#.#.##..#.#.#....#.####.......#.#.#######.#..#....#.###.#...###.##....###.#.#..#.#.##.####.
|
||||||
|
...##.......######.....##....#...#..#.##.###.#..#.##.###.#.###.#.#.#...#.#...##.##.##..#.##########.
|
||||||
|
###..#....#.#.....#....###.#...##.......##.#.#..#.#...########......###..##.#..#..####.##..####...#.
|
||||||
|
......##.###.#.###.....#..#...#.#......##....#....#........#..#...##.##.....#...##.##.........##....
|
||||||
|
.##.##.#.#...#....######..##....##..##.#.#.##.#.##..##...#..###......##......#.#....#.#.#.......###.
|
||||||
|
.......#.##..##.#...#.##..#..#####.#..#.######.........###.#####.####.#...##...........##...##..####
|
||||||
|
#......#.#..#...#...##..#.#.###.##.##.#.#..#.###.##.#..###..#.###..#...###.##..###..#...#..###...#..
|
||||||
|
####.##..#####..####.#...#..#..###..##.#.#...#...#...#.##.####.##.###....###...#.#.#..####.######.##
|
||||||
|
.....#..####...#.#.#.####..####..##.###......#.....########.#...#.#..#..#...#.###..##.#####..###.###
|
||||||
|
.#######.#.##..###.#...###.#####............##.###...#.##.#.##..##.#.#..#.######..######..#..#..####
|
||||||
|
...##..#.####...#..#.#.##.#....#.####..#..###.###..#.#...#....##.##.#......##..##..#.#.#.###..#..#..
|
||||||
|
........#...#.##.#.#..#....####....#.##...###..####...###.#.#..######..###..##.#####.###.###.#.#...#
|
||||||
|
##......##.#..###.####.##.#.###.#.......#.##..####..#.###.##..##..##...##...#.###...#.#..#..#.#####.
|
||||||
|
##..#.#.....##.####.#..##.#.##.#.#...#...#.#...####.#.#.##...##....##.###..###.####.#...#.###..#####
|
||||||
|
.#####.####.####.####.#.##.##......###....###.####...###...#...#..#.##.#.#####.###..##.#..###...##..
|
||||||
|
.#...#..##...##...#....#.#.#..##..#.##..#.###.#.###..###.#.#.###.#....#######.####.##..#..#...####..
|
||||||
|
..##.##..#.##..#.#.###..#.##.########...####.#.###.##..#..###.###...##..##.#..#.######.##.#....###.#
|
||||||
|
##.#####.###.##.#.##.##.##.###..##..##..#.#.#.#.####..#......#.#.#.#.#.#.##...#####.####...#.#...#.#
|
||||||
|
.#..###..##.#####.#.##.#..##...##..##...#####.#.####..#...##.....######.#.#...##.#..#######.###.###.
|
||||||
|
#.#..##.#.#####.#.#.....###.###.#..##.#####....#.###.##.##.#.#..##..#.#....#######.###.#.#.....#.###
|
||||||
|
....###...#.###.####....###.....##....#####.##.###.###.##.##.##.#..###..######...####.#.#..####..#..
|
||||||
|
###.....#..####..#.####..#..#...##.##..##.######.####.....#...##....#..#.##.#####..###.##.#.####...#
|
||||||
|
.##.##.#...#..####...##.##.###...#...#..#.#.#####.....####...#.#.#..#.####...####.#...###.#......###
|
||||||
|
###.##....#.#.#...#.###....####..##...##.##.##.#..#...####..#..#..##...#####.####.####...##.#..###.#
|
||||||
|
..####.....##..###.#.#.###.########..#...#.##..#.#.#.......#.##.#..#...####.##.#..#.######..#.#...#.
|
||||||
|
#.#.##.#.#.##.#....##......##......#######.#..#.##...##..#.#.###...#.#..#..###...#..###.....##.....#
|
||||||
|
..#.##.#.##.#.##..##.....#.#..#.#..#...##..#..#.#....###.#####....####.####..#####.##.###...#..###.#
|
||||||
|
#....#.###..#..########.###..#.#.#.##...##.#..##.###..#..#..#.#.##..###...###.#.##..#.##.#..#.#.####
|
||||||
|
#.......#######......#...#...##.##...###.#....##.#..#....####.#.##.###...#.#####...##.###........##.
|
||||||
|
.##.####.....###.##......####.###.########..#.####..#.##.#.####.....#...#.##....#######.##..#......#
|
||||||
|
#.#.##.##....##..##.#.###..#.##.#..#..#.#..##.....###..###.##.##.####.##.#.#.##...####..#.#..##.#.#.
|
||||||
|
...##.#.#.#...###.#.......#.#.....#.#...##....##.##.##.####...#.#..#..#..#.#.##.#..#.#.#....###..#.#
|
||||||
|
....#.#.###.#####.##..###..##..#...#.##.#......##.####.#..####.#.##..####.#.#...##..#####..##.#.#...
|
||||||
|
..###.#.##..#....#..#.#.....##.#####..##....#.#...#.##..##.#.#..#...##.##..##..##....#...#..#..#..##
|
||||||
|
##.#.##.#...#.###.##.##.##.##..##.##...#..##.#..#######.#..#...#.#.##..#....##.#..####.###........#.
|
||||||
|
.##.#..#.....#####..##.#.#.#.#..###.#######.###.###....##....#.#.#.###....###.#..#.#....#.#..###...#
|
||||||
|
...###.#.#.###..#...#..###.######..##.#.#..#...####.#####.##..#..###...#..#..#..###..##.#.#...#.###.
|
||||||
|
#......#.#..#..##.##.#.##.#.###.#.##.#.#..#....#.##..#..##..##.#.#.#....##.###.###.####.#.#####...##
|
||||||
|
...#.##..#.######.......#.#.###.....#####....##.#.#.###........#.#.###.#.#########.##.##.#..##..#...
|
||||||
|
##..###..###....####.##.##..##.###....####..##...####.####..####..###.####..##.#...###.#####.##.##.#
|
||||||
|
###...##.#.#.#####..#..#####...##.#...#.#.###.#..##..###.##.#.#.....####.##.#..##.###.#...##.##...##
|
||||||
|
...#.#.##.##..##....#..#.#####.##.###..#.#.#........####.###.##....##....####..#.#....#.#.#.###..#.#
|
||||||
|
..#.#.#.#.###...#....##..######.##....#.#.##..###..#.#.###..#.##..#.#.###......#..#..#.####..#...##.
|
||||||
|
.....####.#.....###.#.##.#..##.#..###.#####.#..##...###.#..###..#..##....###.#..##.#..#.##.#..#...##
|
45
y2015/resources/19_input.txt
Normal file
45
y2015/resources/19_input.txt
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
Al => ThF
|
||||||
|
Al => ThRnFAr
|
||||||
|
B => BCa
|
||||||
|
B => TiB
|
||||||
|
B => TiRnFAr
|
||||||
|
Ca => CaCa
|
||||||
|
Ca => PB
|
||||||
|
Ca => PRnFAr
|
||||||
|
Ca => SiRnFYFAr
|
||||||
|
Ca => SiRnMgAr
|
||||||
|
Ca => SiTh
|
||||||
|
F => CaF
|
||||||
|
F => PMg
|
||||||
|
F => SiAl
|
||||||
|
H => CRnAlAr
|
||||||
|
H => CRnFYFYFAr
|
||||||
|
H => CRnFYMgAr
|
||||||
|
H => CRnMgYFAr
|
||||||
|
H => HCa
|
||||||
|
H => NRnFYFAr
|
||||||
|
H => NRnMgAr
|
||||||
|
H => NTh
|
||||||
|
H => OB
|
||||||
|
H => ORnFAr
|
||||||
|
Mg => BF
|
||||||
|
Mg => TiMg
|
||||||
|
N => CRnFAr
|
||||||
|
N => HSi
|
||||||
|
O => CRnFYFAr
|
||||||
|
O => CRnMgAr
|
||||||
|
O => HP
|
||||||
|
O => NRnFAr
|
||||||
|
O => OTi
|
||||||
|
P => CaP
|
||||||
|
P => PTi
|
||||||
|
P => SiRnFAr
|
||||||
|
Si => CaSi
|
||||||
|
Th => ThCa
|
||||||
|
Ti => BP
|
||||||
|
Ti => TiTi
|
||||||
|
e => HF
|
||||||
|
e => NAl
|
||||||
|
e => OMg
|
||||||
|
|
||||||
|
CRnCaSiRnBSiRnFArTiBPTiTiBFArPBCaSiThSiRnTiBPBPMgArCaSiRnTiMgArCaSiThCaSiRnFArRnSiRnFArTiTiBFArCaCaSiRnSiThCaCaSiRnMgArFYSiRnFYCaFArSiThCaSiThPBPTiMgArCaPRnSiAlArPBCaCaSiRnFYSiThCaRnFArArCaCaSiRnPBSiRnFArMgYCaCaCaCaSiThCaCaSiAlArCaCaSiRnPBSiAlArBCaCaCaCaSiThCaPBSiThPBPBCaSiRnFYFArSiThCaSiRnFArBCaCaSiRnFYFArSiThCaPBSiThCaSiRnPMgArRnFArPTiBCaPRnFArCaCaCaCaSiRnCaCaSiRnFYFArFArBCaSiThFArThSiThSiRnTiRnPMgArFArCaSiThCaPBCaSiRnBFArCaCaPRnCaCaPMgArSiRnFYFArCaSiThRnPBPMgAr
|
3
y2015/resources/21_input.txt
Normal file
3
y2015/resources/21_input.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
Hit Points: 103
|
||||||
|
Damage: 9
|
||||||
|
Armor: 2
|
2
y2015/resources/22_input.txt
Normal file
2
y2015/resources/22_input.txt
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
Hit Points: 71
|
||||||
|
Damage: 10
|
49
y2015/resources/23_input.txt
Normal file
49
y2015/resources/23_input.txt
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
jio a, +19
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
jmp +23
|
||||||
|
tpl a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
inc a
|
||||||
|
tpl a
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
jio a, +8
|
||||||
|
inc b
|
||||||
|
jie a, +4
|
||||||
|
tpl a
|
||||||
|
inc a
|
||||||
|
jmp +2
|
||||||
|
hlf a
|
||||||
|
jmp -7
|
29
y2015/resources/24_input.txt
Normal file
29
y2015/resources/24_input.txt
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
1
|
||||||
|
2
|
||||||
|
3
|
||||||
|
5
|
||||||
|
7
|
||||||
|
13
|
||||||
|
17
|
||||||
|
19
|
||||||
|
23
|
||||||
|
29
|
||||||
|
31
|
||||||
|
37
|
||||||
|
41
|
||||||
|
43
|
||||||
|
53
|
||||||
|
59
|
||||||
|
61
|
||||||
|
67
|
||||||
|
71
|
||||||
|
73
|
||||||
|
79
|
||||||
|
83
|
||||||
|
89
|
||||||
|
97
|
||||||
|
101
|
||||||
|
103
|
||||||
|
107
|
||||||
|
109
|
||||||
|
113
|
1
y2015/resources/25_input.txt
Normal file
1
y2015/resources/25_input.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
To continue, please consult the code grid in the manual. Enter the code at row 2981, column 3075.
|
300
y2015/resources/8_input.txt
Normal file
300
y2015/resources/8_input.txt
Normal file
@@ -0,0 +1,300 @@
|
|||||||
|
"\xa8br\x8bjr\""
|
||||||
|
"nq"
|
||||||
|
"zjrfcpbktjmrzgsz\xcaqsc\x03n\"huqab"
|
||||||
|
"daz\\zyyxddpwk"
|
||||||
|
"draes\xa2n\\g\x27ek\"lj\"\\viqych"
|
||||||
|
"nnx\\krnrfomdnt\x2flbl\xd2xpo\"cp\"k"
|
||||||
|
"kwdaapalq"
|
||||||
|
"u\"ptk"
|
||||||
|
"ckhorczuiudfjmmcc\\u\"wozqxibsfjma"
|
||||||
|
"ydctdrxat\"pd\"lwi\"bjesevfw\xe8"
|
||||||
|
"v\"\xa8rrzep\"\"r"
|
||||||
|
"nbydghkfvmq\\\xe0\"lfsrsvlsj\"i\x61liif"
|
||||||
|
"jsas\"u"
|
||||||
|
"odipikxlo"
|
||||||
|
"\"rnubsgwltqkbsu\"pcpcs"
|
||||||
|
"eitk\\f\\mhcqqoym\\ji"
|
||||||
|
"vnedc"
|
||||||
|
"\"lhcaurdqzyjyu"
|
||||||
|
"haxzsa\"zcn\"y\"foclgtjfcnv\"m\x68krc"
|
||||||
|
"\"eoeggg\"tmiydvcay\"vfavc"
|
||||||
|
"snqvyqoncwxcvwbdktoywch"
|
||||||
|
"rnfgjsyr\xd5wacy"
|
||||||
|
"ik\"hebrpvsts"
|
||||||
|
"txw"
|
||||||
|
"\x15pxtdkogd\"urbm\"gevhh\"nxr\x3erxtk"
|
||||||
|
"cetqtcy"
|
||||||
|
"inleep\\mgl"
|
||||||
|
"uflwbxvww\x2cxzezqnaply\"yh\"qlllzk"
|
||||||
|
"eepak\"xqtedzt"
|
||||||
|
"na\x61qzfieafvyrsnwkssznohjmc"
|
||||||
|
"yceaonylz\xc1\\jrlbbkzwsidfi"
|
||||||
|
"ybqafngkcqpbp"
|
||||||
|
"\xaft"
|
||||||
|
"yidjpaobqydso"
|
||||||
|
"ju\\ldxig\\lrdrhjcmm\x77rc"
|
||||||
|
"tylacqeslnwj\x48ds\"tjxa"
|
||||||
|
"efbfm"
|
||||||
|
"\\fxkgoprgdcjgyajykg\\dtbrz"
|
||||||
|
"eujvva"
|
||||||
|
"h\x7acwfpikme\\vwthyvrqdnx\""
|
||||||
|
"rbpbrxm\\\"\"\"voxx"
|
||||||
|
"ykiw\"tkb\\lforu\"rsf\\tf\"x\"rqti"
|
||||||
|
"e\\wh\x77aqeugiq\\ihhfqfuaij"
|
||||||
|
"g\"t\\o"
|
||||||
|
"nxzo\"hf\\xp"
|
||||||
|
"dxiaqfo\xea"
|
||||||
|
"kali\\zczhiqkqzybjj\"fgdjnik"
|
||||||
|
"zdkgrqmdv"
|
||||||
|
"bimxim\xb6lrwsaj\"ui\"a"
|
||||||
|
"\"rrznitibgx\\olpsjmjqzctxaubdifsq"
|
||||||
|
"zb\"khzixaacmhuzmlymoformipdzml"
|
||||||
|
"qfwi"
|
||||||
|
"hjwsxfpphttjy\"\"zixais\xbblgnqfto"
|
||||||
|
"puj\\qmyu\"nqgaqfthbwjokbmrpbhpi"
|
||||||
|
"cyxdpkh\\\""
|
||||||
|
"q"
|
||||||
|
"m"
|
||||||
|
"tbxdzzllarlo"
|
||||||
|
"gbtys"
|
||||||
|
"gytilk\\vlqxvcuutjunrqc"
|
||||||
|
"uugkvcuzan\\eyhb"
|
||||||
|
"yaxr\"genlbgw\"\\uc"
|
||||||
|
"nrgecjeip\\sjdvgqaqxwsqactopu"
|
||||||
|
"pu\"r\"txpyrkfny\\zmwfneyvwmnkkdipv"
|
||||||
|
"jm\xa3bhwvq"
|
||||||
|
"qxojmnml\"w\x9airr"
|
||||||
|
"xbzsuihs\x4dcedy\xaclrhgii\\\""
|
||||||
|
"drgjirusrekrwmvxllwdm"
|
||||||
|
"\x28hfxnfpycmpnkku\"csuf\xaarxlqyg\"x"
|
||||||
|
"\"zvz\\rmg\"\\sxxoifffyqfyn\"iq\"ps"
|
||||||
|
"\"z"
|
||||||
|
"zbwkmk\"sgzos\x93gtc\""
|
||||||
|
"bvm\x28aa\\\\\"pywuhaniox\\z\\hbp\xd7mold"
|
||||||
|
"aszgvsyna"
|
||||||
|
"qf\"vdwuss"
|
||||||
|
"lnohni\"qwiacjsjegstlbfq\\kyjhyd"
|
||||||
|
"c\\naawulxlqplnacvytspry\xf5ytxxqq"
|
||||||
|
"razwqmsqgbaaxcd\\f"
|
||||||
|
"radggyrjrg\"zx"
|
||||||
|
"\"pu\x11t\\ajcjuieinlkvya"
|
||||||
|
"veggiskh"
|
||||||
|
"eglfhjxiet\"kouqfskwsy\"hpthsldel"
|
||||||
|
"mv\xc1b\"f\\shrssnjwcpmurepdxdlcj"
|
||||||
|
"dlayjd\"suvzotgdtc"
|
||||||
|
"\xa9pvxeopn"
|
||||||
|
"lpplsaxy\"oiwaq"
|
||||||
|
"hqwh\\lusv"
|
||||||
|
"hykykwlx\"\xa5atkgh\\d\x63dff"
|
||||||
|
"vfktanpjy\"xxetc"
|
||||||
|
"dnhwkgjnsmsswfuelvihvjl\"jtf"
|
||||||
|
"x\"dwvzra\"nbbsewftehczgbvfzd\"rau"
|
||||||
|
"csfi\"mzejnjqkqupwadrgti\"von"
|
||||||
|
"xckf\xf7xsm\\pgvlpetjndpyblais\\z"
|
||||||
|
"yecy\x6fuj\x58bwpgeuiw\"mdu"
|
||||||
|
"fgb"
|
||||||
|
"c\\lx\x3efthet\xfdelgvwvpem"
|
||||||
|
"kgyrmarvfwjinlowt"
|
||||||
|
"yzte"
|
||||||
|
"vc\"z"
|
||||||
|
"sxevqfzmmdwsuu\""
|
||||||
|
"fxbaercmcy\xb6md"
|
||||||
|
"f"
|
||||||
|
"m\x44gqbcppho\\b"
|
||||||
|
"gtafr\x57m\x11jy\"\"erwmmpiwjkbckuw"
|
||||||
|
"ufdjt\"kssprzxqixzxmq\x58q"
|
||||||
|
"yzbyo\"lfdbyaxexyfbnyv\\\xe8xmre"
|
||||||
|
"u\x43ntr\\\\byyfjr\"iveujvnwsqbnpuvrta"
|
||||||
|
"us\xf6bai"
|
||||||
|
"c\\edh"
|
||||||
|
"tzckolphexfq\\\x23\xfbdqv\\\"m"
|
||||||
|
"yjafhbvhhj\x1b\"bplb"
|
||||||
|
"\"o"
|
||||||
|
"rubahvmp\""
|
||||||
|
"qmkukrnrmqumh"
|
||||||
|
"wdpxyvyidhwjf\\nabbijwhr\xc5bksvy\"p"
|
||||||
|
"u\"prlpg\""
|
||||||
|
"nsvcquyxbwilsxxemf\xd9leq"
|
||||||
|
"y\xcetxuafl"
|
||||||
|
"it"
|
||||||
|
"kwdlysf\\xjpelae"
|
||||||
|
"viwh\x58wpjjlnvryuti\x2chngrx\\nhtkui"
|
||||||
|
"vhn\x9ehre\xc3ncsqbozms\"nl"
|
||||||
|
"ytc\xa3mgeeogjcqavmmmd"
|
||||||
|
"xzlexlitseozoxtpzzutfq"
|
||||||
|
"cish\x07lmovj"
|
||||||
|
"ekbflwqzaiivdr\"pq\\azrfbntqwkn"
|
||||||
|
"uc\"xdbegmlmhksofzohavtrnxf"
|
||||||
|
"xfdnrdqdrcjzbe"
|
||||||
|
"ndg\"ckgrpisib\"rg\"p\\lmpfzlssnvk"
|
||||||
|
"witfjwpbyyzlop"
|
||||||
|
"zonlww\"emrbcsgdtrg\"rjzy\x64zqntlw"
|
||||||
|
"dvgb\"zn\\vrbzema\"ckmd"
|
||||||
|
"\\vdlmxhlvldk\"pmzazeip"
|
||||||
|
"\"\"r"
|
||||||
|
"rsntinv"
|
||||||
|
"iy"
|
||||||
|
"lr\x20efh"
|
||||||
|
"csgexlb\"zqdavlxxhtdbh\"\"\x0fkpvhiphm"
|
||||||
|
"ouwhp\"ogbft"
|
||||||
|
"cm\\ckltng\"dw\x8brf\xf0eppgckd"
|
||||||
|
"zmnlsgalhpkejsizfsbtnfliu\"nhc"
|
||||||
|
"pnrkaayqvwpdjbhcrbb\"yfeq\"aq"
|
||||||
|
"ozh\\hoxow\x2csrtr\\r\""
|
||||||
|
"bqxabj\"u\\s"
|
||||||
|
"cpsjti\"gy"
|
||||||
|
"aa\"p\\nki\\ajijkqev"
|
||||||
|
"q\"\"lfdentjgd\\"
|
||||||
|
"bmokvpoebutfki"
|
||||||
|
"pielvcbne\xf6efvzxn"
|
||||||
|
"kx"
|
||||||
|
"zlgmqagcrbhrwtwtmmg"
|
||||||
|
"aiyhmntcqjbpv\xb5hhswxbryoedvos"
|
||||||
|
"tdpaxrb"
|
||||||
|
"fu\"\x7dttkyvhrlwko"
|
||||||
|
"oirc\\\"cqlnqffjqt\\k"
|
||||||
|
"edxlia\\tcyby"
|
||||||
|
"jpeybgwfayerfrfbvfog\"ol"
|
||||||
|
"ysr"
|
||||||
|
"bzwzilgwfugjk"
|
||||||
|
"tlcc\x75nukvwjgftetjcs\xaecwc"
|
||||||
|
"dsqssa\"vzrf\"sewbp\\ahhlmhbeihlh"
|
||||||
|
"qtgmjck\"n\"guki\"gmdivwqxismqj"
|
||||||
|
"\"f"
|
||||||
|
"wuorvlovucngbzdszqpikyk"
|
||||||
|
"dfrdsacoukmgvhbq\"\"iwto"
|
||||||
|
"\"ey\"ch\\wcgioe\\\"ouvligmsw"
|
||||||
|
"ciqlszzgs"
|
||||||
|
"\\tzyrkaoi\"sopjaq"
|
||||||
|
"lmtnv"
|
||||||
|
"ar\"fqoroigiertjjlm\"ymgi\\kkjewsxd"
|
||||||
|
"wehcimlvudpxtamdn\"rwy"
|
||||||
|
"hr\"zvrwthr\"vruzqfrldn\"b"
|
||||||
|
"sggekodkiwvym\"mhsco"
|
||||||
|
"ltlkfbrrdvk\\"
|
||||||
|
"uut\"sfjnz\"\\ef"
|
||||||
|
"hxilg\\"
|
||||||
|
"zsredsiwlzrpedibn"
|
||||||
|
"vtfi"
|
||||||
|
"\\h"
|
||||||
|
"qekfrc\xf6wduodbwrguqcng\\n"
|
||||||
|
"\"lljlfdrxftwidn\\pkv\xd9ij"
|
||||||
|
"mrvgqynpehkliuijlpp"
|
||||||
|
"gikjph"
|
||||||
|
"yoxcdrdt\"wbaurnyhoyxoihu"
|
||||||
|
"onmomwuxuammbzxe"
|
||||||
|
"rnrr\\twviz\x61gqaljr\x0dmtw"
|
||||||
|
"r\"vupaoi"
|
||||||
|
"l"
|
||||||
|
"sei"
|
||||||
|
"jwxtdtbkd\\kxd"
|
||||||
|
"\x22v\\"
|
||||||
|
"ahd"
|
||||||
|
"j\"bjqxs"
|
||||||
|
"\\i\x24gglxub\\nzsajokt"
|
||||||
|
"lviwpu\"uxdlh\\zuy\"xqy\"ytdzlx\"r"
|
||||||
|
"kptfmys"
|
||||||
|
"fwxzikfhczkjwyjszqdbkepaeellc"
|
||||||
|
"nlqpsvbrbd\\ns"
|
||||||
|
"qryuwkjiodw\"\"vaqyq\"dmyifm"
|
||||||
|
"tw\x15kdmaudjl\\zorhp\"alwh"
|
||||||
|
"aatrvczesykekkjfyb\"kb"
|
||||||
|
"usqcutbqbxxhucwxo\xc1ltb\"j\"bghjcvws"
|
||||||
|
"ilhsrnzxkz"
|
||||||
|
"bianqfdfdhvw"
|
||||||
|
"hqibqs\x7ax\"qoxqoaqtcsz"
|
||||||
|
"htxtoojbbauztwxuiq\\ngyfy\\obzc"
|
||||||
|
"rxn\\moxlj"
|
||||||
|
"mtus\x84erh\"dbe"
|
||||||
|
"asx\x50huvsitcxadt"
|
||||||
|
"\"bugggtnrc\"\"kl\"hmpu\x83hqrvhpo"
|
||||||
|
"ewisbp\"\"vuzf\\w\x5fvalszdhl"
|
||||||
|
"scusplpwxfnxu\x57\"zynpn\x99xerc\\ri"
|
||||||
|
"m\\kinmkke\x0cl"
|
||||||
|
"xhuzit\x7fd"
|
||||||
|
"kfbo\x04\x50ruqirn"
|
||||||
|
"t\"\"xpbdscmdoug"
|
||||||
|
"punvpsgnbgyxe\"sptmpz"
|
||||||
|
"bxukkazijr"
|
||||||
|
"nxyrcdaoo\"rjkk\"wntehcvcip\"vrd"
|
||||||
|
"rdpvqskmihqaw"
|
||||||
|
"p\\gwdhtqnpgthod"
|
||||||
|
"nwnuf\"\"yebycearom\"nqym\"\xd4sii\xccle"
|
||||||
|
"alda\"ptspo\"wkkv\"zoi\"hkb\"vnntyd"
|
||||||
|
"ixpgpfzbqv"
|
||||||
|
"znui\"\\fzn\x03qozabh\"rva\"pv\x67"
|
||||||
|
"e\"zswmwuk"
|
||||||
|
"hcccygwfa"
|
||||||
|
"ngmace\\rtyllolr\"\x68bw"
|
||||||
|
"\\c\"jyufbry\"ryo\"xpo\x26ecninfeckh\\s"
|
||||||
|
"hdnpngtuc\"dzbvvosn\x31fwtpzbrt"
|
||||||
|
"hesbpd\xd4"
|
||||||
|
"dsdbstuzrdfmrnyntufs\"dmv"
|
||||||
|
"d\xeeibcwhcvkt"
|
||||||
|
"fvzwrsfjdqdmy\"\"v"
|
||||||
|
"ns\"dqafz\\lkyoflnazv\"mn\x37\"o\"yj\"e"
|
||||||
|
"dypilgbwzccayxa\"bnmuernx"
|
||||||
|
"q\xa9ztqrhreb\"\"kxfeyodqb"
|
||||||
|
"iz\xa5qjxqulaawuwz\"rqmpcj\\yel"
|
||||||
|
"z\"\\pq\"\"y\x67zpjtn"
|
||||||
|
"ifxqvivp\"kiiftdoe"
|
||||||
|
"jxzebj\"\x35\"qr\"ecglcutuoyywqumcs\"kk"
|
||||||
|
"q"
|
||||||
|
"yob\x85qmpuwexptczbkrl"
|
||||||
|
"cjiavv\"uudpozvibyycnmxhxpxmpjoz"
|
||||||
|
"xro\\uiqyrcid"
|
||||||
|
"nod\\k"
|
||||||
|
"d\"neiec"
|
||||||
|
"tqyrqvwyvmz\\pzgzzcqsqsrgbqbtapoz"
|
||||||
|
"r\"xvocpeuxfxslgueb\x05kzyyie\"aoec"
|
||||||
|
"\"du\\uirlhcbgv\\cjqhfreqnvn"
|
||||||
|
"zp\x04\x15\"pbjwhrjtmiba"
|
||||||
|
"\\cv\""
|
||||||
|
"k\"rwnb\\hiu\"rqd\"rc\\nyakrhly"
|
||||||
|
"klrmafjzandiddodgz"
|
||||||
|
"xipzhqzhvlpykzcuppx"
|
||||||
|
"zdvrvn\xd0mtfvpylbn\\\\sxcznrzugwznl"
|
||||||
|
"ody\\pvm\"kpjiudzhxazirgxzvumeat\"o"
|
||||||
|
"kllvhdp\"prjikzrrc\"adgpegc\\\"gk"
|
||||||
|
"sqtpug\xbcaauxaamw"
|
||||||
|
"wegxxrrxdvpivrqievfeokmnojsk"
|
||||||
|
"\\bo"
|
||||||
|
"gijhz"
|
||||||
|
"ylowluvabwrigssdgtxdwsiorxev\xdd"
|
||||||
|
"\""
|
||||||
|
"ghnsrnsqtxpygikahkrl"
|
||||||
|
"\"rcfqkbjf\"sgxg\"vnd\\rotn"
|
||||||
|
"ap\"smgsuexjrbuqs\"mpbstogj\"x"
|
||||||
|
"koaunz\\sgt\"opv"
|
||||||
|
"yialiuzwix"
|
||||||
|
"yp\"ndxgwzml\"bt"
|
||||||
|
"lpcjxmggfsy\\szbxccarjkqzasqkb\xcfd\x0c"
|
||||||
|
"x"
|
||||||
|
"mgakc"
|
||||||
|
"vjieunoh\x73fjwx"
|
||||||
|
"erbvv\"qulsd"
|
||||||
|
"mimycrbfhqkarmz"
|
||||||
|
"tihfbgcszuej\"c\xfbvoqskkhbgpaddioo"
|
||||||
|
"mziavkwrmekriqghw"
|
||||||
|
"izk\\tnjd\\ed\\emokvjoc"
|
||||||
|
"c\"nhbqzndro\\g"
|
||||||
|
"usfngdo"
|
||||||
|
"aypljdftvptt"
|
||||||
|
"ym\"afvq\xbcc"
|
||||||
|
"zabi\"wjpvugwhl"
|
||||||
|
"ebvptcjqjhc\"n\"p\"dxrphegr\\"
|
||||||
|
"mzlqqxokhye\xd9\\rffhnzs"
|
||||||
|
"hnipqknwpsjakanuewe"
|
||||||
|
"rqgbfcjdrmiz\"h"
|
||||||
|
"kzzp\\z\\txmkwaouxictybwx"
|
||||||
|
"yzmspjkqrteiydswlvb"
|
||||||
|
"gjpxklgpzv\"txri\\hotpuiukzzzd"
|
||||||
|
"p\"rxergtbsxmjmkeeqwvoagnki\""
|
||||||
|
"santipvuiq"
|
||||||
|
"\"ihjqlhtwbuy\"hdkiv\"mtiqacnf\\"
|
||||||
|
"oliaggtqyyx"
|
||||||
|
"fwwnpmbb"
|
||||||
|
"yrtdrieazfxyyneo"
|
||||||
|
"nywbv\\"
|
||||||
|
"twc\\ehfqxhgomgrgwpxyzmnkioj"
|
||||||
|
"qludrkkvljljd\\xvdeum\x4e"
|
28
y2015/resources/9_input.txt
Normal file
28
y2015/resources/9_input.txt
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
Tristram to AlphaCentauri = 34
|
||||||
|
Tristram to Snowdin = 100
|
||||||
|
Tristram to Tambi = 63
|
||||||
|
Tristram to Faerun = 108
|
||||||
|
Tristram to Norrath = 111
|
||||||
|
Tristram to Straylight = 89
|
||||||
|
Tristram to Arbre = 132
|
||||||
|
AlphaCentauri to Snowdin = 4
|
||||||
|
AlphaCentauri to Tambi = 79
|
||||||
|
AlphaCentauri to Faerun = 44
|
||||||
|
AlphaCentauri to Norrath = 147
|
||||||
|
AlphaCentauri to Straylight = 133
|
||||||
|
AlphaCentauri to Arbre = 74
|
||||||
|
Snowdin to Tambi = 105
|
||||||
|
Snowdin to Faerun = 95
|
||||||
|
Snowdin to Norrath = 48
|
||||||
|
Snowdin to Straylight = 88
|
||||||
|
Snowdin to Arbre = 7
|
||||||
|
Tambi to Faerun = 68
|
||||||
|
Tambi to Norrath = 134
|
||||||
|
Tambi to Straylight = 107
|
||||||
|
Tambi to Arbre = 40
|
||||||
|
Faerun to Norrath = 11
|
||||||
|
Faerun to Straylight = 66
|
||||||
|
Faerun to Arbre = 144
|
||||||
|
Norrath to Straylight = 115
|
||||||
|
Norrath to Arbre = 135
|
||||||
|
Straylight to Arbre = 127
|
@@ -1,20 +1,27 @@
|
|||||||
use std::fs;
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
use y2015::days::d1;
|
use y2015::days::d1;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
part1();
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
part2();
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part1() {
|
fn part1() {
|
||||||
let root = env!("CARGO_MANIFEST_DIR");
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
let content = fs::read_to_string(format!("{root}/resources/1_input.txt")).unwrap();
|
let content = fs::read_to_string(format!("{root}/resources/1_input.txt")).unwrap();
|
||||||
println!("{}", d1::process_part1(&content));
|
println!("Answer: {}", d1::process_part1(&content));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part2() {
|
fn part2() {
|
||||||
let root = env!("CARGO_MANIFEST_DIR");
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
let content = fs::read_to_string(format!("{root}/resources/1_input.txt")).unwrap();
|
let content = fs::read_to_string(format!("{root}/resources/1_input.txt")).unwrap();
|
||||||
println!("{}", d1::process_part2(&content));
|
println!("Answer: {}", d1::process_part2(&content));
|
||||||
}
|
}
|
||||||
|
23
y2015/src/bin/d10.rs
Normal file
23
y2015/src/bin/d10.rs
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
use std::time::Instant;
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d10;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
println!("{}", d10::process_part1("1321131112"));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
println!("{}", d10::process_part2("1321131112"));
|
||||||
|
}
|
23
y2015/src/bin/d11.rs
Normal file
23
y2015/src/bin/d11.rs
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
use std::time::Instant;
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d11;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
println!("{}", d11::process_part1("hepxcrrq"));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
println!("{}", d11::process_part1(&d11::process_part1("hepxcrrq")));
|
||||||
|
}
|
27
y2015/src/bin/d12.rs
Normal file
27
y2015/src/bin/d12.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d12;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/12_input.txt")).unwrap();
|
||||||
|
println!("{}", d12::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/12_input.txt")).unwrap();
|
||||||
|
println!("{}", d12::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d13.rs
Normal file
27
y2015/src/bin/d13.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d13;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/13_input.txt")).unwrap();
|
||||||
|
println!("{}", d13::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/13_input.txt")).unwrap();
|
||||||
|
println!("{}", d13::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d14.rs
Normal file
27
y2015/src/bin/d14.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d14;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/14_input.txt")).unwrap();
|
||||||
|
println!("{}", d14::process_part1(&content, 2503));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/14_input.txt")).unwrap();
|
||||||
|
println!("{}", d14::process_part2(&content, 2503));
|
||||||
|
}
|
28
y2015/src/bin/d15.rs
Normal file
28
y2015/src/bin/d15.rs
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d15;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/15_input.txt")).unwrap();
|
||||||
|
println!("{}", d15::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
//let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
//let content = fs::read_to_string(format!("{root}/resources/15_input.txt")).unwrap();
|
||||||
|
// change comments in part1
|
||||||
|
//println!("{}", d15::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d16.rs
Normal file
27
y2015/src/bin/d16.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d16;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/16_input.txt")).unwrap();
|
||||||
|
println!("{}", d16::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/16_input.txt")).unwrap();
|
||||||
|
println!("{}", d16::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d17.rs
Normal file
27
y2015/src/bin/d17.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d17;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/17_input.txt")).unwrap();
|
||||||
|
println!("{}", d17::process_part1(&content, 150));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/17_input.txt")).unwrap();
|
||||||
|
println!("{}", d17::process_part2(&content, 150));
|
||||||
|
}
|
27
y2015/src/bin/d18.rs
Normal file
27
y2015/src/bin/d18.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d18;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/18_input.txt")).unwrap();
|
||||||
|
println!("{}", d18::process_part1(&content, 100));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/18_input.txt")).unwrap();
|
||||||
|
println!("{}", d18::process_part2(&content, 100));
|
||||||
|
}
|
27
y2015/src/bin/d19.rs
Normal file
27
y2015/src/bin/d19.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d19;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/19_input.txt")).unwrap();
|
||||||
|
println!("{}", d19::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/19_input.txt")).unwrap();
|
||||||
|
println!("{}", d19::process_part2(&content));
|
||||||
|
}
|
@@ -1,10 +1,17 @@
|
|||||||
use std::fs;
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
use y2015::days::d2;
|
use y2015::days::d2;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
part1();
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
part2();
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part1() {
|
fn part1() {
|
||||||
|
23
y2015/src/bin/d20.rs
Normal file
23
y2015/src/bin/d20.rs
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
use std::time::Instant;
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d20;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
println!("{}", d20::process_part1(36000000));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
println!("{}", d20::process_part2(36000000));
|
||||||
|
}
|
27
y2015/src/bin/d21.rs
Normal file
27
y2015/src/bin/d21.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d21;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/21_input.txt")).unwrap();
|
||||||
|
println!("{}", d21::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/21_input.txt")).unwrap();
|
||||||
|
println!("{}", d21::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d22.rs
Normal file
27
y2015/src/bin/d22.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d22;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/22_input.txt")).unwrap();
|
||||||
|
println!("{}", d22::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/22_input.txt")).unwrap();
|
||||||
|
println!("{}", d22::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d23.rs
Normal file
27
y2015/src/bin/d23.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d23;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/23_input.txt")).unwrap();
|
||||||
|
println!("{:?}", d23::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/23_input.txt")).unwrap();
|
||||||
|
println!("{:?}", d23::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d24.rs
Normal file
27
y2015/src/bin/d24.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d24;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/24_input.txt")).unwrap();
|
||||||
|
println!("{}", d24::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/24_input.txt")).unwrap();
|
||||||
|
println!("{}", d24::process_part2(&content));
|
||||||
|
}
|
15
y2015/src/bin/d25.rs
Normal file
15
y2015/src/bin/d25.rs
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
use std::time::Instant;
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d25;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
println!("{}", d25::process_part1(3075, 2981));
|
||||||
|
}
|
@@ -1,10 +1,17 @@
|
|||||||
use std::fs;
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
use y2015::days::d3;
|
use y2015::days::d3;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
part1();
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
part2();
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part1() {
|
fn part1() {
|
||||||
|
@@ -1,10 +1,17 @@
|
|||||||
use std::time::Instant;
|
use std::time::Instant;
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
use y2015::days::d4;
|
use y2015::days::d4;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
part1();
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
part2();
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part1() {
|
fn part1() {
|
||||||
|
@@ -1,10 +1,17 @@
|
|||||||
use std::fs;
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
use y2015::days::d5;
|
use y2015::days::d5;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
part1();
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
part2();
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part1() {
|
fn part1() {
|
||||||
|
@@ -1,10 +1,17 @@
|
|||||||
use std::fs;
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
use y2015::days::d6;
|
use y2015::days::d6;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
part1();
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
part2();
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part1() {
|
fn part1() {
|
||||||
|
@@ -1,10 +1,17 @@
|
|||||||
use std::fs;
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
use y2015::days::d7;
|
use y2015::days::d7;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
part1();
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
part2();
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
}
|
}
|
||||||
|
|
||||||
fn part1() {
|
fn part1() {
|
||||||
@@ -16,5 +23,5 @@ fn part1() {
|
|||||||
fn part2() {
|
fn part2() {
|
||||||
let root = env!("CARGO_MANIFEST_DIR");
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
let content = fs::read_to_string(format!("{root}/resources/7_input.txt")).unwrap();
|
let content = fs::read_to_string(format!("{root}/resources/7_input.txt")).unwrap();
|
||||||
println!("{:#?}", d7::process_part2(&content));
|
println!("{}", d7::process_part2(&content).get("a").unwrap());
|
||||||
}
|
}
|
||||||
|
27
y2015/src/bin/d8.rs
Normal file
27
y2015/src/bin/d8.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d8;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/8_input.txt")).unwrap();
|
||||||
|
println!("{}", d8::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/8_input.txt")).unwrap();
|
||||||
|
println!("{}", d8::process_part2(&content));
|
||||||
|
}
|
27
y2015/src/bin/d9.rs
Normal file
27
y2015/src/bin/d9.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2015::days::d9;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/9_input.txt")).unwrap();
|
||||||
|
println!("{}", d9::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/9_input.txt")).unwrap();
|
||||||
|
println!("{}", d9::process_part2(&content));
|
||||||
|
}
|
@@ -39,11 +39,11 @@ pub fn process_part2(input: &str) -> i32 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests_1 {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn it_works() {
|
fn part1() {
|
||||||
let result = process_part1("(())");
|
let result = process_part1("(())");
|
||||||
assert_eq!(result, 0);
|
assert_eq!(result, 0);
|
||||||
let result = process_part1("(())");
|
let result = process_part1("(())");
|
||||||
|
57
y2015/src/days/d10.rs
Normal file
57
y2015/src/days/d10.rs
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
let mut number = input.to_string();
|
||||||
|
for _ in 0..40 {
|
||||||
|
number = look_and_say(&number);
|
||||||
|
}
|
||||||
|
number.len() as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
let mut number = input.to_string();
|
||||||
|
for _ in 0..50 {
|
||||||
|
number = look_and_say(&number);
|
||||||
|
}
|
||||||
|
number.len() as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
fn look_and_say(number: &str) -> String {
|
||||||
|
let mut new_number = String::new();
|
||||||
|
let mut last_char = 'x';
|
||||||
|
let mut char_counter = 1;
|
||||||
|
for (idx, char) in number.chars().enumerate() {
|
||||||
|
if char == last_char {
|
||||||
|
char_counter += 1;
|
||||||
|
} else {
|
||||||
|
if idx != 0 {
|
||||||
|
new_number.push_str(format!("{char_counter}").as_str());
|
||||||
|
new_number.push(last_char);
|
||||||
|
}
|
||||||
|
last_char = char;
|
||||||
|
char_counter = 1;
|
||||||
|
}
|
||||||
|
if idx == number.len() - 1 {
|
||||||
|
new_number.push_str(format!("{char_counter}").as_str());
|
||||||
|
new_number.push(char);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
new_number
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = look_and_say("1");
|
||||||
|
assert_eq!(result, "11".to_string());
|
||||||
|
let result = look_and_say("11");
|
||||||
|
assert_eq!(result, "21".to_string());
|
||||||
|
let result = look_and_say("21");
|
||||||
|
assert_eq!(result, "1211".to_string());
|
||||||
|
let result = look_and_say("1211");
|
||||||
|
assert_eq!(result, "111221".to_string());
|
||||||
|
let result = look_and_say("111221");
|
||||||
|
assert_eq!(result, "312211".to_string());
|
||||||
|
}
|
||||||
|
}
|
70
y2015/src/days/d11.rs
Normal file
70
y2015/src/days/d11.rs
Normal file
@@ -0,0 +1,70 @@
|
|||||||
|
pub fn process_part1(input: &str) -> String {
|
||||||
|
let mut password = input.to_string();
|
||||||
|
loop {
|
||||||
|
password = increment(&password);
|
||||||
|
if password.contains("i") || password.contains("o") || password.contains("l") {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if !has_straight(&password) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if num_pairs(&password) < 2 {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
return password;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn has_straight(password: &str) -> bool {
|
||||||
|
for window in password.as_bytes().windows(3) {
|
||||||
|
let (a, b, c) = (window[0], window[1], window[2]);
|
||||||
|
let (inc_b, inc_c) = (increment_letter(a), increment_letter(b));
|
||||||
|
if b == inc_b.0 && c == inc_c.0 && !(inc_b.1 || inc_c.1) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
false
|
||||||
|
}
|
||||||
|
|
||||||
|
fn num_pairs(password: &str) -> u32 {
|
||||||
|
let mut num_pairs = 0;
|
||||||
|
let mut was_last_pair = false;
|
||||||
|
password.as_bytes().windows(2).for_each(|window| {
|
||||||
|
if window[0] == window[1] && !was_last_pair {
|
||||||
|
num_pairs += 1;
|
||||||
|
was_last_pair = true;
|
||||||
|
} else {
|
||||||
|
was_last_pair = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
num_pairs
|
||||||
|
}
|
||||||
|
|
||||||
|
fn increment(password: &str) -> String {
|
||||||
|
let mut password_bytes = password.as_bytes().to_vec();
|
||||||
|
password_bytes.reverse();
|
||||||
|
let mut new_password_bytes = vec![];
|
||||||
|
let mut increment_next = true;
|
||||||
|
for letter in password_bytes {
|
||||||
|
if increment_next {
|
||||||
|
let (new_letter, overflow) = increment_letter(letter);
|
||||||
|
new_password_bytes.push(new_letter);
|
||||||
|
increment_next = overflow;
|
||||||
|
} else {
|
||||||
|
new_password_bytes.push(letter);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if increment_next {
|
||||||
|
new_password_bytes.push(b'a');
|
||||||
|
}
|
||||||
|
new_password_bytes.reverse();
|
||||||
|
String::from_utf8(new_password_bytes).unwrap()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn increment_letter(letter: u8) -> (u8, bool) {
|
||||||
|
if letter == b'z' {
|
||||||
|
(b'a', true)
|
||||||
|
} else {
|
||||||
|
(letter + 1, false)
|
||||||
|
}
|
||||||
|
}
|
177
y2015/src/days/d12.rs
Normal file
177
y2015/src/days/d12.rs
Normal file
@@ -0,0 +1,177 @@
|
|||||||
|
pub fn process_part1(input: &str) -> i32 {
|
||||||
|
let mut sum = 0;
|
||||||
|
let mut number = String::new();
|
||||||
|
for &byte in input.as_bytes() {
|
||||||
|
if byte == b'-' || byte.is_ascii_digit() {
|
||||||
|
number.push(byte as char);
|
||||||
|
} else if !number.is_empty() {
|
||||||
|
sum += number.parse::<i32>().unwrap();
|
||||||
|
number.clear();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
sum
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> i32 {
|
||||||
|
let red_indices = input
|
||||||
|
.match_indices("red")
|
||||||
|
.map(|(idx, _)| idx)
|
||||||
|
.collect::<Vec<usize>>();
|
||||||
|
let mut red_objects = Vec::new();
|
||||||
|
let mut last_range = (0, 0);
|
||||||
|
for idx in red_indices {
|
||||||
|
if idx > last_range.0 && idx < last_range.1 {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
let (left, right) = input.split_at(idx);
|
||||||
|
let open = find_open(left);
|
||||||
|
let close = find_close(right) + idx as u32;
|
||||||
|
let range = (open as usize, close as usize + 1);
|
||||||
|
last_range = range;
|
||||||
|
if !red_objects.contains(&range) {
|
||||||
|
red_objects.push(range);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
red_objects.reverse();
|
||||||
|
// remove overlaps not caught during creation
|
||||||
|
let mut last_range = (0, 0);
|
||||||
|
let mut no_overlap = Vec::new();
|
||||||
|
for range in red_objects.clone() {
|
||||||
|
if last_range.0 < range.0 && last_range.1 > range.1 {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
last_range = range;
|
||||||
|
no_overlap.push(range);
|
||||||
|
}
|
||||||
|
let mut unreded_input = input.to_owned();
|
||||||
|
for range in no_overlap {
|
||||||
|
unreded_input.replace_range(range.0..range.1, "0");
|
||||||
|
}
|
||||||
|
process_part1(&unreded_input)
|
||||||
|
}
|
||||||
|
|
||||||
|
fn find_open(string: &str) -> u32 {
|
||||||
|
let mut bytes = string.as_bytes().to_vec();
|
||||||
|
bytes.reverse();
|
||||||
|
let length = bytes.len();
|
||||||
|
// count of traversed objects
|
||||||
|
// increments when seeing } decrements when seeing {
|
||||||
|
// while == 0, potentially inside an object
|
||||||
|
// while > 0 peeking inside another object
|
||||||
|
// when < 0 left object red is inside of
|
||||||
|
// when == 0 and encountered [ then inside array
|
||||||
|
let mut curly_count = 0;
|
||||||
|
let mut square_count = 0;
|
||||||
|
let mut idx = length - 1;
|
||||||
|
for byte in bytes {
|
||||||
|
if byte == b'}' {
|
||||||
|
curly_count += 1
|
||||||
|
} else if byte == b'{' {
|
||||||
|
curly_count -= 1
|
||||||
|
} else if byte == b'[' {
|
||||||
|
square_count -= 1;
|
||||||
|
} else if byte == b']' {
|
||||||
|
square_count += 1;
|
||||||
|
}
|
||||||
|
if square_count < 0 {
|
||||||
|
return length as u32 - 1;
|
||||||
|
}
|
||||||
|
if curly_count < 0 || idx == 0 {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
idx -= 1;
|
||||||
|
}
|
||||||
|
if curly_count < 0 {
|
||||||
|
idx as u32
|
||||||
|
} else {
|
||||||
|
length as u32
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn find_close(string: &str) -> u32 {
|
||||||
|
let bytes = string.as_bytes().to_vec();
|
||||||
|
let length = bytes.len();
|
||||||
|
// count of traversed objects
|
||||||
|
// increments when seeing { decrements when seeing }
|
||||||
|
// while == 0, potentially inside an object
|
||||||
|
// while > 0 peeking inside another object
|
||||||
|
// when < 0 left object red is inside of
|
||||||
|
// when == 0 and encountered ] then inside array
|
||||||
|
let mut curly_count = 0;
|
||||||
|
let mut square_count = 0;
|
||||||
|
let mut idx = 0;
|
||||||
|
for byte in bytes {
|
||||||
|
if byte == b'}' {
|
||||||
|
curly_count -= 1
|
||||||
|
} else if byte == b'{' {
|
||||||
|
curly_count += 1
|
||||||
|
} else if byte == b']' {
|
||||||
|
square_count -= 1;
|
||||||
|
} else if byte == b'[' {
|
||||||
|
square_count += 1;
|
||||||
|
}
|
||||||
|
if square_count < 0 {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
if curly_count < 0 || idx == length {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
if curly_count < 0 {
|
||||||
|
idx as u32
|
||||||
|
} else {
|
||||||
|
0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result_a = process_part1("[1,2,3]");
|
||||||
|
let result_b = process_part1(r#"{"a":2,"b":4}"#);
|
||||||
|
assert_eq!(result_a, 6);
|
||||||
|
assert_eq!(result_b, 6);
|
||||||
|
let result_a = process_part1("[[[3]]]");
|
||||||
|
let result_b = process_part1(r#"{"a":{"b":4},"c":-1}"#);
|
||||||
|
assert_eq!(result_a, 3);
|
||||||
|
assert_eq!(result_b, 3);
|
||||||
|
let result_a = process_part1(r#"{"a":[-1,1]}"#);
|
||||||
|
let result_b = process_part1(r#"[-1,{"a":1}]"#);
|
||||||
|
assert_eq!(result_a, 0);
|
||||||
|
assert_eq!(result_b, 0);
|
||||||
|
let result_a = process_part1("[]");
|
||||||
|
let result_b = process_part1("{}");
|
||||||
|
assert_eq!(result_a, 0);
|
||||||
|
assert_eq!(result_b, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
//let result_a = process_part2("[1,2,3]");
|
||||||
|
//let result_b = process_part2(r#"{"a":2,"b":4}"#);
|
||||||
|
//assert_eq!(result_a, 6);
|
||||||
|
//assert_eq!(result_b, 6);
|
||||||
|
//let result_a = process_part2("[[[3]]]");
|
||||||
|
//let result_b = process_part2(r#"{"a":{"b":4},"c":-1}"#);
|
||||||
|
//assert_eq!(result_a, 3);
|
||||||
|
//assert_eq!(result_b, 3);
|
||||||
|
//let result_a = process_part2(r#"{"a":[-1,1]}"#);
|
||||||
|
//let result_b = process_part2(r#"[-1,{"a":1}]"#);
|
||||||
|
//assert_eq!(result_a, 0);
|
||||||
|
//assert_eq!(result_b, 0);
|
||||||
|
//let result_a = process_part2("[]");
|
||||||
|
//let result_b = process_part2("{}");
|
||||||
|
//assert_eq!(result_a, 0);
|
||||||
|
//assert_eq!(result_b, 0);
|
||||||
|
let result_a = process_part2(r#"[1,{"c":"red","b":2},3]"#);
|
||||||
|
assert_eq!(result_a, 4);
|
||||||
|
let result_a = process_part2(r#"{"d":"red","e":[1,2,3,4],"f":5}"#);
|
||||||
|
assert_eq!(result_a, 0);
|
||||||
|
let result_a = process_part2(r#"[1,"red",5]"#);
|
||||||
|
assert_eq!(result_a, 6);
|
||||||
|
}
|
||||||
|
}
|
156
y2015/src/days/d13.rs
Normal file
156
y2015/src/days/d13.rs
Normal file
@@ -0,0 +1,156 @@
|
|||||||
|
use core::panic;
|
||||||
|
use std::collections::HashMap;
|
||||||
|
|
||||||
|
use utils::{math::factorial, permutation};
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> i32 {
|
||||||
|
let mut happiness_table = HashMap::new();
|
||||||
|
let mut people = Vec::new();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let words = line.split_whitespace().collect::<Vec<&str>>();
|
||||||
|
let happiness = match words[2] {
|
||||||
|
"gain" => words[3].parse::<i32>().expect("Should be number"),
|
||||||
|
"lose" => -words[3].parse::<i32>().expect("Should be number"),
|
||||||
|
_ => panic!("Should not happen"),
|
||||||
|
};
|
||||||
|
let person = words[0].to_string();
|
||||||
|
let mut next_to = words[10].to_string();
|
||||||
|
next_to.pop();
|
||||||
|
if !people.contains(&person) {
|
||||||
|
people.push(person.clone());
|
||||||
|
}
|
||||||
|
happiness_table.insert((person, next_to), happiness);
|
||||||
|
});
|
||||||
|
|
||||||
|
let num_people = people.len();
|
||||||
|
|
||||||
|
let possible_permutations = factorial(num_people.try_into().unwrap());
|
||||||
|
|
||||||
|
let mut highest_happiness = 0;
|
||||||
|
for idx in 1..possible_permutations {
|
||||||
|
let mut happiness = 0;
|
||||||
|
let permutation = permutation::nth_lex(people.clone(), idx.try_into().unwrap()).unwrap();
|
||||||
|
|
||||||
|
for (pos, person) in permutation.clone().iter().enumerate() {
|
||||||
|
let left_neighbor = {
|
||||||
|
if pos == 0 {
|
||||||
|
permutation[num_people - 1].clone()
|
||||||
|
} else {
|
||||||
|
permutation[pos - 1].clone()
|
||||||
|
}
|
||||||
|
};
|
||||||
|
let right_neighbor = {
|
||||||
|
if pos == num_people - 1 {
|
||||||
|
permutation[0].clone()
|
||||||
|
} else {
|
||||||
|
permutation[pos + 1].clone()
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
let left_happiness = happiness_table
|
||||||
|
.get(&(person.to_owned(), left_neighbor))
|
||||||
|
.unwrap();
|
||||||
|
let right_happiness = happiness_table
|
||||||
|
.get(&(person.to_owned(), right_neighbor))
|
||||||
|
.unwrap();
|
||||||
|
happiness += left_happiness + right_happiness;
|
||||||
|
}
|
||||||
|
|
||||||
|
if happiness > highest_happiness {
|
||||||
|
highest_happiness = happiness;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
highest_happiness
|
||||||
|
}
|
||||||
|
pub fn process_part2(input: &str) -> i32 {
|
||||||
|
let mut happiness_table = HashMap::new();
|
||||||
|
let mut people = Vec::new();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let words = line.split_whitespace().collect::<Vec<&str>>();
|
||||||
|
let happiness = match words[2] {
|
||||||
|
"gain" => words[3].parse::<i32>().expect("Should be number"),
|
||||||
|
"lose" => -words[3].parse::<i32>().expect("Should be number"),
|
||||||
|
_ => panic!("Should not happen"),
|
||||||
|
};
|
||||||
|
let person = words[0].to_string();
|
||||||
|
let mut next_to = words[10].to_string();
|
||||||
|
next_to.pop();
|
||||||
|
if !people.contains(&person) {
|
||||||
|
people.push(person.clone());
|
||||||
|
}
|
||||||
|
happiness_table.insert((person, next_to), happiness);
|
||||||
|
});
|
||||||
|
|
||||||
|
for person in &people {
|
||||||
|
happiness_table.insert(("Fabian".to_string(), person.to_owned()), 0);
|
||||||
|
happiness_table.insert((person.to_owned(), "Fabian".to_string()), 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
people.push("Fabian".to_string());
|
||||||
|
|
||||||
|
let num_people = people.len();
|
||||||
|
|
||||||
|
let possible_permutations = factorial(num_people.try_into().unwrap());
|
||||||
|
|
||||||
|
let mut highest_happiness = 0;
|
||||||
|
for idx in 1..possible_permutations {
|
||||||
|
let mut happiness = 0;
|
||||||
|
let permutation = permutation::nth_lex(people.clone(), idx.try_into().unwrap()).unwrap();
|
||||||
|
|
||||||
|
for (pos, person) in permutation.clone().iter().enumerate() {
|
||||||
|
let left_neighbor = {
|
||||||
|
if pos == 0 {
|
||||||
|
permutation[num_people - 1].clone()
|
||||||
|
} else {
|
||||||
|
permutation[pos - 1].clone()
|
||||||
|
}
|
||||||
|
};
|
||||||
|
let right_neighbor = {
|
||||||
|
if pos == num_people - 1 {
|
||||||
|
permutation[0].clone()
|
||||||
|
} else {
|
||||||
|
permutation[pos + 1].clone()
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
let left_happiness = happiness_table
|
||||||
|
.get(&(person.to_owned(), left_neighbor))
|
||||||
|
.unwrap();
|
||||||
|
let right_happiness = happiness_table
|
||||||
|
.get(&(person.to_owned(), right_neighbor))
|
||||||
|
.unwrap();
|
||||||
|
happiness += left_happiness + right_happiness;
|
||||||
|
}
|
||||||
|
|
||||||
|
if happiness > highest_happiness {
|
||||||
|
highest_happiness = happiness;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
highest_happiness
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "Alice would gain 54 happiness units by sitting next to Bob.
|
||||||
|
Alice would lose 79 happiness units by sitting next to Carol.
|
||||||
|
Alice would lose 2 happiness units by sitting next to David.
|
||||||
|
Bob would gain 83 happiness units by sitting next to Alice.
|
||||||
|
Bob would lose 7 happiness units by sitting next to Carol.
|
||||||
|
Bob would lose 63 happiness units by sitting next to David.
|
||||||
|
Carol would lose 62 happiness units by sitting next to Alice.
|
||||||
|
Carol would gain 60 happiness units by sitting next to Bob.
|
||||||
|
Carol would gain 55 happiness units by sitting next to David.
|
||||||
|
David would gain 46 happiness units by sitting next to Alice.
|
||||||
|
David would lose 7 happiness units by sitting next to Bob.
|
||||||
|
David would gain 41 happiness units by sitting next to Carol.";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 330);
|
||||||
|
}
|
||||||
|
}
|
125
y2015/src/days/d14.rs
Normal file
125
y2015/src/days/d14.rs
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
use std::fmt::Display;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str, time: u32) -> u32 {
|
||||||
|
let mut reindeer_stats = vec![];
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let words = line.split_whitespace().collect::<Vec<&str>>();
|
||||||
|
let name = words[0].to_string();
|
||||||
|
let speed = words[3].parse::<u32>().unwrap();
|
||||||
|
let travel_time = words[6].parse::<u32>().unwrap();
|
||||||
|
let rest_time = words[13].parse::<u32>().unwrap();
|
||||||
|
let reindeer = Reindeer {
|
||||||
|
name,
|
||||||
|
speed,
|
||||||
|
travel_time,
|
||||||
|
rest_time,
|
||||||
|
score: 0,
|
||||||
|
distance: 0,
|
||||||
|
};
|
||||||
|
reindeer_stats.push(reindeer.distance_traveled(time));
|
||||||
|
});
|
||||||
|
*reindeer_stats.iter().max().unwrap()
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Clone)]
|
||||||
|
struct Reindeer {
|
||||||
|
name: String,
|
||||||
|
speed: u32,
|
||||||
|
travel_time: u32,
|
||||||
|
rest_time: u32,
|
||||||
|
score: u32,
|
||||||
|
distance: u32,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Display for Reindeer {
|
||||||
|
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||||
|
let string = format!(
|
||||||
|
"{}: Speed {} for {}, rest {}",
|
||||||
|
self.name, self.speed, self.travel_time, self.rest_time
|
||||||
|
);
|
||||||
|
writeln!(f, "{string}")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Reindeer {
|
||||||
|
fn distance_traveled(&self, seconds: u32) -> u32 {
|
||||||
|
let timeframe = self.travel_time + self.rest_time;
|
||||||
|
let mut traveled = (seconds / timeframe) * self.speed * self.travel_time;
|
||||||
|
let last_timeframe = seconds % timeframe;
|
||||||
|
if last_timeframe >= self.travel_time {
|
||||||
|
traveled += self.speed * self.travel_time;
|
||||||
|
} else {
|
||||||
|
traveled += self.speed * last_timeframe;
|
||||||
|
}
|
||||||
|
traveled
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str, time: u32) -> u32 {
|
||||||
|
let mut reindeer_stats = vec![];
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let words = line.split_whitespace().collect::<Vec<&str>>();
|
||||||
|
let name = words[0].to_string();
|
||||||
|
let speed = words[3].parse::<u32>().unwrap();
|
||||||
|
let travel_time = words[6].parse::<u32>().unwrap();
|
||||||
|
let rest_time = words[13].parse::<u32>().unwrap();
|
||||||
|
let reindeer = Reindeer {
|
||||||
|
name,
|
||||||
|
speed,
|
||||||
|
travel_time,
|
||||||
|
rest_time,
|
||||||
|
score: 0,
|
||||||
|
distance: 0,
|
||||||
|
};
|
||||||
|
reindeer_stats.push(reindeer);
|
||||||
|
});
|
||||||
|
for second in 1..=time {
|
||||||
|
let mut furthest = (String::new(), 0);
|
||||||
|
let mut reindeers = reindeer_stats
|
||||||
|
.iter()
|
||||||
|
.map(|reindeer| {
|
||||||
|
let reindeer = reindeer.clone();
|
||||||
|
Reindeer {
|
||||||
|
distance: reindeer.distance_traveled(second),
|
||||||
|
..reindeer
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.collect::<Vec<Reindeer>>();
|
||||||
|
reindeers.iter().for_each(|reindeer| {
|
||||||
|
if reindeer.distance >= furthest.1 {
|
||||||
|
furthest = (reindeer.name.clone(), reindeer.distance);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
reindeers.iter_mut().for_each(|reindeer| {
|
||||||
|
if reindeer.name == furthest.0 {
|
||||||
|
reindeer.score += 1;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
reindeer_stats = reindeers;
|
||||||
|
}
|
||||||
|
reindeer_stats
|
||||||
|
.iter()
|
||||||
|
.map(|reindeer| reindeer.score)
|
||||||
|
.max()
|
||||||
|
.unwrap()
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "Comet can fly 14 km/s for 10 seconds, but then must rest for 127 seconds.
|
||||||
|
Dancer can fly 16 km/s for 11 seconds, but then must rest for 162 seconds.";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT, 1000);
|
||||||
|
assert_eq!(result, 1120);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT, 1000);
|
||||||
|
assert_eq!(result, 689);
|
||||||
|
}
|
||||||
|
}
|
188
y2015/src/days/d15.rs
Normal file
188
y2015/src/days/d15.rs
Normal file
@@ -0,0 +1,188 @@
|
|||||||
|
use std::ops::Mul;
|
||||||
|
|
||||||
|
#[derive(Debug, Clone)]
|
||||||
|
struct Ingredient {
|
||||||
|
name: String,
|
||||||
|
capacity: i64,
|
||||||
|
durability: i64,
|
||||||
|
flavor: i64,
|
||||||
|
texture: i64,
|
||||||
|
calories: i64,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Ingredient {
|
||||||
|
fn score(ingredients: Vec<Self>) -> i64 {
|
||||||
|
let capacity = ingredients
|
||||||
|
.iter()
|
||||||
|
.map(|ingredient| ingredient.capacity)
|
||||||
|
.sum::<i64>();
|
||||||
|
let durability = ingredients
|
||||||
|
.iter()
|
||||||
|
.map(|ingredient| ingredient.durability)
|
||||||
|
.sum::<i64>();
|
||||||
|
let flavor = ingredients
|
||||||
|
.iter()
|
||||||
|
.map(|ingredient| ingredient.flavor)
|
||||||
|
.sum::<i64>();
|
||||||
|
let texture = ingredients
|
||||||
|
.iter()
|
||||||
|
.map(|ingredient| ingredient.texture)
|
||||||
|
.sum::<i64>();
|
||||||
|
if capacity < 0 || durability < 0 || flavor < 0 || texture < 0 {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
capacity * durability * flavor * texture
|
||||||
|
//* (self.calories + other.calories)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
impl PartialOrd for Ingredient {
|
||||||
|
fn partial_cmp(&self, other: &Self) -> Option<std::cmp::Ordering> {
|
||||||
|
Some(self.cmp(other))
|
||||||
|
}
|
||||||
|
|
||||||
|
fn lt(&self, other: &Self) -> bool {
|
||||||
|
std::matches!(self.partial_cmp(other), Some(std::cmp::Ordering::Less))
|
||||||
|
}
|
||||||
|
|
||||||
|
fn le(&self, other: &Self) -> bool {
|
||||||
|
std::matches!(
|
||||||
|
self.partial_cmp(other),
|
||||||
|
Some(std::cmp::Ordering::Less | std::cmp::Ordering::Equal)
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
fn gt(&self, other: &Self) -> bool {
|
||||||
|
std::matches!(self.partial_cmp(other), Some(std::cmp::Ordering::Greater))
|
||||||
|
}
|
||||||
|
|
||||||
|
fn ge(&self, other: &Self) -> bool {
|
||||||
|
std::matches!(
|
||||||
|
self.partial_cmp(other),
|
||||||
|
Some(std::cmp::Ordering::Greater | std::cmp::Ordering::Equal)
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Ord for Ingredient {
|
||||||
|
fn cmp(&self, other: &Self) -> std::cmp::Ordering {
|
||||||
|
let score = self.capacity + self.durability + self.flavor + self.texture + self.calories;
|
||||||
|
let other_score =
|
||||||
|
other.capacity + other.durability + other.flavor + other.texture + other.calories;
|
||||||
|
score.cmp(&other_score)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
impl PartialEq for Ingredient {
|
||||||
|
fn eq(&self, other: &Self) -> bool {
|
||||||
|
self.capacity + self.durability + self.flavor + self.texture + self.calories
|
||||||
|
== other.capacity + other.durability + other.flavor + other.texture + other.calories
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Eq for Ingredient {}
|
||||||
|
|
||||||
|
impl Mul<Ingredient> for i64 {
|
||||||
|
type Output = Ingredient;
|
||||||
|
|
||||||
|
fn mul(self, rhs: Ingredient) -> Self::Output {
|
||||||
|
Ingredient {
|
||||||
|
name: rhs.name,
|
||||||
|
capacity: rhs.capacity * self,
|
||||||
|
durability: rhs.durability * self,
|
||||||
|
flavor: rhs.flavor * self,
|
||||||
|
texture: rhs.texture * self,
|
||||||
|
calories: rhs.calories * self,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Mul<i64> for Ingredient {
|
||||||
|
type Output = Self;
|
||||||
|
|
||||||
|
fn mul(self, rhs: i64) -> Self::Output {
|
||||||
|
Ingredient {
|
||||||
|
name: self.name,
|
||||||
|
capacity: self.capacity * rhs,
|
||||||
|
durability: self.durability * rhs,
|
||||||
|
flavor: self.flavor * rhs,
|
||||||
|
texture: self.texture * rhs,
|
||||||
|
calories: self.calories * rhs,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> i64 {
|
||||||
|
let mut ingredients = vec![];
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let (ingredient, props) = line.split_once(": ").unwrap();
|
||||||
|
let ingredient = ingredient.to_string();
|
||||||
|
let props = props
|
||||||
|
.split(", ")
|
||||||
|
.map(|prop| {
|
||||||
|
let (_, value) = prop.split_once(" ").unwrap();
|
||||||
|
value.parse().unwrap()
|
||||||
|
})
|
||||||
|
.collect::<Vec<i64>>();
|
||||||
|
ingredients.push(Ingredient {
|
||||||
|
name: ingredient,
|
||||||
|
capacity: props[0],
|
||||||
|
durability: props[1],
|
||||||
|
flavor: props[2],
|
||||||
|
texture: props[3],
|
||||||
|
calories: props[4],
|
||||||
|
});
|
||||||
|
});
|
||||||
|
let mut biggest_score = 0;
|
||||||
|
// for test
|
||||||
|
//for idx1 in 1..=99 {
|
||||||
|
// for idx2 in 1..=99 {
|
||||||
|
// if idx1 + idx2 != 100 {
|
||||||
|
// continue;
|
||||||
|
// }
|
||||||
|
// let score = Ingredient::score(vec![idx1 * ingredients[0].clone(), idx2 * ingredients[1].clone()]);
|
||||||
|
// if score > biggest_score {
|
||||||
|
// biggest_score = score;
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
// input has 4 ingredients so 4 nested loops
|
||||||
|
for idx1 in 1..=99 {
|
||||||
|
for idx2 in 1..=99 {
|
||||||
|
for idx3 in 1..=97 {
|
||||||
|
for idx4 in 1..=97 {
|
||||||
|
if idx1 + idx2 + idx3 + idx4 != 100 {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
let i1 = idx1 * ingredients[0].clone();
|
||||||
|
let i2 = idx2 * ingredients[1].clone();
|
||||||
|
let i3 = idx3 * ingredients[2].clone();
|
||||||
|
let i4 = idx4 * ingredients[3].clone();
|
||||||
|
// only for part 2
|
||||||
|
if i1.calories + i2.calories + i3.calories + i4.calories != 500 {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
let score = Ingredient::score(vec![i1, i2, i3, i4]);
|
||||||
|
if score > biggest_score {
|
||||||
|
biggest_score = score;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
biggest_score
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "Butterscotch: capacity -1, durability -2, flavor 6, texture 3, calories 8
|
||||||
|
Cinnamon: capacity 2, durability 3, flavor -2, texture -1, calories 3";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 62842880);
|
||||||
|
}
|
||||||
|
}
|
61
y2015/src/days/d16.rs
Normal file
61
y2015/src/days/d16.rs
Normal file
@@ -0,0 +1,61 @@
|
|||||||
|
use std::collections::HashMap;
|
||||||
|
|
||||||
|
const TAPE: &str = "children: 3
|
||||||
|
cats: 7
|
||||||
|
samoyeds: 2
|
||||||
|
pomeranians: 3
|
||||||
|
akitas: 0
|
||||||
|
vizslas: 0
|
||||||
|
goldfish: 5
|
||||||
|
trees: 3
|
||||||
|
cars: 2
|
||||||
|
perfumes: 1";
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> String {
|
||||||
|
let mut tape = HashMap::new();
|
||||||
|
TAPE.lines().for_each(|line| {
|
||||||
|
let (k, v) = line.split_once(": ").unwrap();
|
||||||
|
tape.insert(k, v.parse::<u32>().unwrap());
|
||||||
|
});
|
||||||
|
for line in input.lines() {
|
||||||
|
let (sue, params) = line.split_once(": ").unwrap();
|
||||||
|
let mut is_correct = true;
|
||||||
|
params.split(", ").for_each(|param| {
|
||||||
|
let (k, v) = param.split_once(": ").unwrap();
|
||||||
|
if v.parse::<u32>().unwrap() != *tape.get(k).unwrap() {
|
||||||
|
is_correct = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
if is_correct {
|
||||||
|
return sue.to_string();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
"".to_string()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> String {
|
||||||
|
let mut tape = HashMap::new();
|
||||||
|
TAPE.lines().for_each(|line| {
|
||||||
|
let (k, v) = line.split_once(": ").unwrap();
|
||||||
|
tape.insert(k, v.parse::<u32>().unwrap());
|
||||||
|
});
|
||||||
|
for line in input.lines() {
|
||||||
|
let (sue, params) = line.split_once(": ").unwrap();
|
||||||
|
let mut is_correct = true;
|
||||||
|
params.split(", ").for_each(|param| {
|
||||||
|
let (k, v) = param.split_once(": ").unwrap();
|
||||||
|
let v = v.parse::<u32>().unwrap();
|
||||||
|
let tape_value = *tape.get(k).unwrap();
|
||||||
|
if (["cats", "trees"].contains(&k) && v <= tape_value)
|
||||||
|
|| (["pomeranians", "goldfish"].contains(&k) && v >= tape_value)
|
||||||
|
|| (!["cats", "trees", "pomeranians", "goldfish"].contains(&k) && v != tape_value)
|
||||||
|
{
|
||||||
|
is_correct = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
if is_correct {
|
||||||
|
return sue.to_string();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
"".to_string()
|
||||||
|
}
|
66
y2015/src/days/d17.rs
Normal file
66
y2015/src/days/d17.rs
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
use utils::combination;
|
||||||
|
use utils::math::binomial;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str, litres: u32) -> u32 {
|
||||||
|
let containers = input
|
||||||
|
.lines()
|
||||||
|
.map(|container| container.parse::<u32>().unwrap())
|
||||||
|
.collect::<Vec<u32>>();
|
||||||
|
let mut correct_combinations = Vec::new();
|
||||||
|
for k in 1..=containers.len() {
|
||||||
|
let num_combinations =
|
||||||
|
binomial(containers.len().try_into().unwrap(), k.try_into().unwrap());
|
||||||
|
for i in 1..=num_combinations {
|
||||||
|
let res = combination::nth_lex(containers.clone(), k, i.try_into().unwrap()).unwrap();
|
||||||
|
if res.iter().sum::<u32>() == litres {
|
||||||
|
correct_combinations.push(res);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
correct_combinations.len() as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str, litres: u32) -> u32 {
|
||||||
|
let containers = input
|
||||||
|
.lines()
|
||||||
|
.map(|container| container.parse::<u32>().unwrap())
|
||||||
|
.collect::<Vec<u32>>();
|
||||||
|
let mut correct_combinations = Vec::new();
|
||||||
|
for k in 1..=containers.len() {
|
||||||
|
let num_combinations =
|
||||||
|
binomial(containers.len().try_into().unwrap(), k.try_into().unwrap());
|
||||||
|
for i in 1..=num_combinations {
|
||||||
|
let res = combination::nth_lex(containers.clone(), k, i.try_into().unwrap()).unwrap();
|
||||||
|
if res.iter().sum::<u32>() == litres {
|
||||||
|
correct_combinations.push(res);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if !correct_combinations.is_empty() {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
correct_combinations.len() as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "20
|
||||||
|
15
|
||||||
|
10
|
||||||
|
5
|
||||||
|
5";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT, 25);
|
||||||
|
assert_eq!(result, 4);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT, 25);
|
||||||
|
assert_eq!(result, 3);
|
||||||
|
}
|
||||||
|
}
|
179
y2015/src/days/d18.rs
Normal file
179
y2015/src/days/d18.rs
Normal file
@@ -0,0 +1,179 @@
|
|||||||
|
use core::panic;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str, steps: u32) -> i32 {
|
||||||
|
let mut grid = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| line.chars().map(Light::from).collect::<Vec<Light>>())
|
||||||
|
.collect::<Vec<Vec<Light>>>();
|
||||||
|
let height = grid.len();
|
||||||
|
let width = grid[0].len();
|
||||||
|
let mut new_grid = vec![vec![Light::Off; width]; height];
|
||||||
|
for _step in 0..steps {
|
||||||
|
for (y, grid_line) in grid.iter().enumerate() {
|
||||||
|
for (x, light) in grid_line.iter().enumerate() {
|
||||||
|
let neighbors = Light::get_neighbors(grid.clone(), (x, y));
|
||||||
|
new_grid[y][x] = light.new_state(neighbors);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
grid = new_grid.clone();
|
||||||
|
}
|
||||||
|
grid.iter()
|
||||||
|
.map(|line| {
|
||||||
|
line.iter()
|
||||||
|
.map(|&light| if light == Light::On { 1 } else { 0 })
|
||||||
|
.sum::<i32>()
|
||||||
|
})
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str, steps: u32) -> i32 {
|
||||||
|
let mut grid = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| line.chars().map(Light::from).collect::<Vec<Light>>())
|
||||||
|
.collect::<Vec<Vec<Light>>>();
|
||||||
|
let height = grid.len();
|
||||||
|
let width = grid[0].len();
|
||||||
|
let corners = vec![
|
||||||
|
(0, 0),
|
||||||
|
(width - 1, 0),
|
||||||
|
(0, height - 1),
|
||||||
|
(width - 1, height - 1),
|
||||||
|
];
|
||||||
|
for (corner_x, corner_y) in corners.clone() {
|
||||||
|
grid[corner_y][corner_x] = Light::On;
|
||||||
|
}
|
||||||
|
let mut new_grid = vec![vec![Light::Off; width]; height];
|
||||||
|
for _step in 0..steps {
|
||||||
|
for (y, grid_line) in grid.iter().enumerate() {
|
||||||
|
for (x, light) in grid_line.iter().enumerate() {
|
||||||
|
let neighbors = Light::get_neighbors(grid.clone(), (x, y));
|
||||||
|
new_grid[y][x] = light.new_state(neighbors);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
grid = new_grid.clone();
|
||||||
|
for (corner_x, corner_y) in corners.clone() {
|
||||||
|
grid[corner_y][corner_x] = Light::On;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
grid.iter()
|
||||||
|
.map(|line| {
|
||||||
|
line.iter()
|
||||||
|
.map(|&light| if light == Light::On { 1 } else { 0 })
|
||||||
|
.sum::<i32>()
|
||||||
|
})
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Clone, Copy, PartialEq, Eq)]
|
||||||
|
enum Light {
|
||||||
|
On,
|
||||||
|
Off,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Light {
|
||||||
|
fn new_state(self, neighbors: Vec<Light>) -> Self {
|
||||||
|
let mut light = self;
|
||||||
|
match self {
|
||||||
|
Light::On => {
|
||||||
|
if ![2, 3].contains(&Self::count_on(neighbors)) {
|
||||||
|
light = Light::Off;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Light::Off => {
|
||||||
|
if Self::count_on(neighbors) == 3 {
|
||||||
|
light = Light::On;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
light
|
||||||
|
}
|
||||||
|
|
||||||
|
fn count_on(neighbors: Vec<Light>) -> u32 {
|
||||||
|
neighbors
|
||||||
|
.iter()
|
||||||
|
.map(|&light| if light == Light::On { 1 } else { 0 })
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn get_neighbors(grid: Vec<Vec<Light>>, coords: (usize, usize)) -> Vec<Light> {
|
||||||
|
let relative_coords = vec![
|
||||||
|
(-1, -1),
|
||||||
|
(0, -1),
|
||||||
|
(1, -1),
|
||||||
|
(-1, 0),
|
||||||
|
(1, 0),
|
||||||
|
(-1, 1),
|
||||||
|
(0, 1),
|
||||||
|
(1, 1),
|
||||||
|
];
|
||||||
|
let height = grid.len();
|
||||||
|
let width = grid[0].len();
|
||||||
|
let (x, y) = coords;
|
||||||
|
let mut neighbors = Vec::new();
|
||||||
|
for (relative_x, relative_y) in relative_coords {
|
||||||
|
let neighbor_x = x.checked_add_signed(relative_x);
|
||||||
|
if neighbor_x.is_none() {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
let neighbor_x = neighbor_x.unwrap();
|
||||||
|
let neighbor_y = y.checked_add_signed(relative_y);
|
||||||
|
if neighbor_y.is_none() {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
let neighbor_y = neighbor_y.unwrap();
|
||||||
|
if neighbor_x >= width || neighbor_y >= height {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
neighbors.push(grid[neighbor_y][neighbor_x]);
|
||||||
|
}
|
||||||
|
neighbors
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
impl From<char> for Light {
|
||||||
|
fn from(value: char) -> Self {
|
||||||
|
match value {
|
||||||
|
'#' => Light::On,
|
||||||
|
'.' => Light::Off,
|
||||||
|
_ => panic!("Wrong character"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[allow(unused)]
|
||||||
|
fn print_grid(grid: Vec<Vec<Light>>) {
|
||||||
|
grid.iter().for_each(|line| {
|
||||||
|
line.iter().for_each(|&light| {
|
||||||
|
if light == Light::On {
|
||||||
|
print!("#");
|
||||||
|
} else {
|
||||||
|
print!(".");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
println!();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = ".#.#.#
|
||||||
|
...##.
|
||||||
|
#....#
|
||||||
|
..#...
|
||||||
|
#.#..#
|
||||||
|
####..";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT, 4);
|
||||||
|
assert_eq!(result, 4);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT, 5);
|
||||||
|
assert_eq!(result, 17);
|
||||||
|
}
|
||||||
|
}
|
110
y2015/src/days/d19.rs
Normal file
110
y2015/src/days/d19.rs
Normal file
@@ -0,0 +1,110 @@
|
|||||||
|
use std::collections::HashSet;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
let (replacements_str, molecule) = input.split_once("\n\n").unwrap();
|
||||||
|
let mut replacements = Vec::new();
|
||||||
|
replacements_str.lines().for_each(|line| {
|
||||||
|
let (from, to) = line.split_once(" => ").unwrap();
|
||||||
|
replacements.push((from, to));
|
||||||
|
});
|
||||||
|
let mut possible = HashSet::new();
|
||||||
|
for (from, to) in replacements {
|
||||||
|
molecule.match_indices(from).for_each(|(idx, _)| {
|
||||||
|
let mut new_possible = molecule.to_string();
|
||||||
|
new_possible.replace_range(idx..(idx + from.len()), to);
|
||||||
|
possible.insert(new_possible);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
possible.len() as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
// https://www.reddit.com/r/adventofcode/comments/3xflz8/comment/cy4etju/
|
||||||
|
// broken test
|
||||||
|
//First insight
|
||||||
|
//
|
||||||
|
//There are only two types of productions:
|
||||||
|
//
|
||||||
|
// e => XX and X => XX (X is not Rn, Y, or Ar)
|
||||||
|
//
|
||||||
|
// X => X Rn X Ar | X Rn X Y X Ar | X Rn X Y X Y X Ar
|
||||||
|
//
|
||||||
|
//Second insight
|
||||||
|
//
|
||||||
|
//You can think of Rn Y Ar as the characters ( , ):
|
||||||
|
//
|
||||||
|
//X => X(X) | X(X,X) | X(X,X,X)
|
||||||
|
//
|
||||||
|
//Whenever there are two adjacent "elements" in your "molecule", you apply the first production. This reduces your molecule length by 1 each time.
|
||||||
|
//
|
||||||
|
//And whenever you have T(T) T(T,T) or T(T,T,T) (T is a literal token such as "Mg", i.e. not a nonterminal like "TiTiCaCa"), you apply the second production. This reduces your molecule length by 3, 5, or 7.
|
||||||
|
//Third insight
|
||||||
|
//
|
||||||
|
//Repeatedly applying X => XX until you arrive at a single token takes count(tokens) - 1 steps:
|
||||||
|
//
|
||||||
|
//ABCDE => XCDE => XDE => XE => X
|
||||||
|
//count("ABCDE") = 5
|
||||||
|
//5 - 1 = 4 steps
|
||||||
|
//
|
||||||
|
//Applying X => X(X) is similar to X => XX, except you get the () for free. This can be expressed as count(tokens) - count("(" or ")") - 1.
|
||||||
|
//
|
||||||
|
//A(B(C(D(E)))) => A(B(C(X))) => A(B(X)) => A(X) => X
|
||||||
|
//count("A(B(C(D(E))))") = 13
|
||||||
|
//count("(((())))") = 8
|
||||||
|
//13 - 8 - 1 = 4 steps
|
||||||
|
//
|
||||||
|
//You can generalize to X => X(X,X) by noting that each , reduces the length by two (,X). The new formula is count(tokens) - count("(" or ")") - 2*count(",") - 1.
|
||||||
|
//
|
||||||
|
//A(B(C,D),E(F,G)) => A(B(C,D),X) => A(X,X) => X
|
||||||
|
//count("A(B(C,D),E(F,G))") = 16
|
||||||
|
//count("(()())") = 6
|
||||||
|
//count(",,,") = 3
|
||||||
|
//16 - 6 - 2*3 - 1 = 3 steps
|
||||||
|
//
|
||||||
|
//This final formula works for all of the production types (for X => XX, the (,) counts are zero by definition.)
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
let (_replacements_str, molecule) = input.split_once("\n\n").unwrap();
|
||||||
|
// An element is always at least an uppercase character and possibly an additional lowercase
|
||||||
|
// character
|
||||||
|
let total_elements = molecule.chars().filter(|char| char.is_uppercase()).count();
|
||||||
|
let num_rn = molecule.matches("Rn").count();
|
||||||
|
let num_ar = molecule.matches("Ar").count();
|
||||||
|
let num_y = molecule.matches("Y").count();
|
||||||
|
(total_elements - (num_rn + num_ar) - 2 * num_y - 1) as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT1: &str = "H => HO
|
||||||
|
H => OH
|
||||||
|
O => HH
|
||||||
|
e => H
|
||||||
|
e => O
|
||||||
|
|
||||||
|
HOH";
|
||||||
|
|
||||||
|
const INPUT2: &str = "H => HO
|
||||||
|
H => OH
|
||||||
|
O => HH
|
||||||
|
e => H
|
||||||
|
e => O
|
||||||
|
|
||||||
|
HOHOHO";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT1);
|
||||||
|
assert_eq!(result, 4);
|
||||||
|
let result = process_part1(INPUT2);
|
||||||
|
assert_eq!(result, 7);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT1);
|
||||||
|
assert_eq!(result, 3);
|
||||||
|
let result = process_part2(INPUT2);
|
||||||
|
assert_eq!(result, 6);
|
||||||
|
}
|
||||||
|
}
|
@@ -37,14 +37,14 @@ pub fn process_part2(input: &str) -> i64 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests_2 {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
const INPUT: &str = "2x3x4
|
const INPUT: &str = "2x3x4
|
||||||
1x1x10";
|
1x1x10";
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn it_works() {
|
fn part1() {
|
||||||
let result = process_part1(INPUT);
|
let result = process_part1(INPUT);
|
||||||
assert_eq!(result, 101);
|
assert_eq!(result, 101);
|
||||||
}
|
}
|
||||||
|
55
y2015/src/days/d20.rs
Normal file
55
y2015/src/days/d20.rs
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
use utils::math::get_divisors;
|
||||||
|
|
||||||
|
pub fn process_part1(input: u32) -> u32 {
|
||||||
|
// slow
|
||||||
|
//let mut house = 1;
|
||||||
|
//loop {
|
||||||
|
// let mut presents = 0;
|
||||||
|
// for elf in 1..=house {
|
||||||
|
// if house % elf == 0 {
|
||||||
|
// presents += elf * 10;
|
||||||
|
// println!("{house} {presents}");
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// if presents >= input {
|
||||||
|
// break;
|
||||||
|
// }
|
||||||
|
// house += 1;
|
||||||
|
//}
|
||||||
|
//house
|
||||||
|
let mut house = 0;
|
||||||
|
loop {
|
||||||
|
house += 1;
|
||||||
|
let mut divisors = get_divisors(house);
|
||||||
|
divisors.push(house);
|
||||||
|
if divisors.iter().sum::<u64>() * 10 >= input.into() {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
house as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: u32) -> u32 {
|
||||||
|
let mut house = 0;
|
||||||
|
loop {
|
||||||
|
house += 1;
|
||||||
|
let mut divisors = get_divisors(house);
|
||||||
|
divisors.push(house);
|
||||||
|
let sum = divisors.iter().filter(|&&d| house / d <= 50).sum::<u64>();
|
||||||
|
if sum * 11 >= input.into() {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
house as u32
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(100);
|
||||||
|
assert_eq!(result, 6);
|
||||||
|
}
|
||||||
|
}
|
269
y2015/src/days/d21.rs
Normal file
269
y2015/src/days/d21.rs
Normal file
@@ -0,0 +1,269 @@
|
|||||||
|
use core::panic;
|
||||||
|
|
||||||
|
// 1 Weapon
|
||||||
|
// 0-1 Armor
|
||||||
|
// 0-2 Rings
|
||||||
|
const SHOP: &str = "Weapons: Cost Damage Armor
|
||||||
|
Dagger 8 4 0
|
||||||
|
Shortsword 10 5 0
|
||||||
|
Warhammer 25 6 0
|
||||||
|
Longsword 40 7 0
|
||||||
|
Greataxe 74 8 0
|
||||||
|
|
||||||
|
Armor: Cost Damage Armor
|
||||||
|
Leather 13 0 1
|
||||||
|
Chainmail 31 0 2
|
||||||
|
Splintmail 53 0 3
|
||||||
|
Bandedmail 75 0 4
|
||||||
|
Platemail 102 0 5
|
||||||
|
|
||||||
|
Rings: Cost Damage Armor
|
||||||
|
Damage +1 25 1 0
|
||||||
|
Damage +2 50 2 0
|
||||||
|
Damage +3 100 3 0
|
||||||
|
Defense +1 20 0 1
|
||||||
|
Defense +2 40 0 2
|
||||||
|
Defense +3 80 0 3";
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
let player = Character {
|
||||||
|
hp: 100,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
let mut boss = Character::default();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let (attribute, value) = line.split_once(": ").unwrap();
|
||||||
|
match attribute {
|
||||||
|
"Hit Points" => {
|
||||||
|
boss.hp = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
"Damage" => {
|
||||||
|
boss.damage = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
"Armor" => {
|
||||||
|
boss.armor = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
_ => panic!("Should not happen"),
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
let mut weapons = Vec::new();
|
||||||
|
let mut armors = Vec::new();
|
||||||
|
let mut rings = Vec::new();
|
||||||
|
|
||||||
|
SHOP.split("\n\n").for_each(|category| {
|
||||||
|
let mut items = category.lines();
|
||||||
|
let (category_name, _) = items.next().unwrap().split_once(":").unwrap();
|
||||||
|
let item_vec = items
|
||||||
|
.map(|item| {
|
||||||
|
let item_vec = item.split_whitespace().collect::<Vec<&str>>();
|
||||||
|
let cols = item_vec.len();
|
||||||
|
let mut name = item_vec[0].to_string();
|
||||||
|
if item_vec[1].contains("+") {
|
||||||
|
name.push_str(item_vec[1]);
|
||||||
|
}
|
||||||
|
Item {
|
||||||
|
name,
|
||||||
|
cost: item_vec[cols - 3].parse::<u32>().unwrap(),
|
||||||
|
damage: item_vec[cols - 2].parse::<u32>().unwrap(),
|
||||||
|
armor: item_vec[cols - 1].parse::<u32>().unwrap(),
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.collect::<Vec<Item>>();
|
||||||
|
match category_name {
|
||||||
|
"Weapons" => weapons = item_vec,
|
||||||
|
"Armor" => armors = item_vec,
|
||||||
|
"Rings" => rings = item_vec,
|
||||||
|
_ => panic!("Should not happen"),
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
//println!("{weapons:#?}");
|
||||||
|
//println!("{armors:#?}");
|
||||||
|
//println!("{rings:#?}");
|
||||||
|
|
||||||
|
rings.sort_by(|ring_a, ring_b| ring_a.cost.cmp(&ring_b.cost));
|
||||||
|
|
||||||
|
let choices = create_item_choices(weapons, armors, rings);
|
||||||
|
let mut lowest_cost = u32::MAX;
|
||||||
|
for (weapon, armor, rings) in choices {
|
||||||
|
let mut current_player = player;
|
||||||
|
current_player.equip(weapon);
|
||||||
|
if let Some(armor) = armor {
|
||||||
|
current_player.equip(armor);
|
||||||
|
}
|
||||||
|
if !rings.is_empty() {
|
||||||
|
for ring in rings {
|
||||||
|
current_player.equip(ring);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if current_player.wins_against(&boss) && current_player.items_value < lowest_cost {
|
||||||
|
lowest_cost = current_player.items_value;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
lowest_cost
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
let player = Character {
|
||||||
|
hp: 100,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
let mut boss = Character::default();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let (attribute, value) = line.split_once(": ").unwrap();
|
||||||
|
match attribute {
|
||||||
|
"Hit Points" => {
|
||||||
|
boss.hp = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
"Damage" => {
|
||||||
|
boss.damage = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
"Armor" => {
|
||||||
|
boss.armor = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
_ => panic!("Should not happen"),
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
let mut weapons = Vec::new();
|
||||||
|
let mut armors = Vec::new();
|
||||||
|
let mut rings = Vec::new();
|
||||||
|
|
||||||
|
SHOP.split("\n\n").for_each(|category| {
|
||||||
|
let mut items = category.lines();
|
||||||
|
let (category_name, _) = items.next().unwrap().split_once(":").unwrap();
|
||||||
|
let item_vec = items
|
||||||
|
.map(|item| {
|
||||||
|
let item_vec = item.split_whitespace().collect::<Vec<&str>>();
|
||||||
|
let cols = item_vec.len();
|
||||||
|
let mut name = item_vec[0].to_string();
|
||||||
|
if item_vec[1].contains("+") {
|
||||||
|
name.push_str(item_vec[1]);
|
||||||
|
}
|
||||||
|
Item {
|
||||||
|
name,
|
||||||
|
cost: item_vec[cols - 3].parse::<u32>().unwrap(),
|
||||||
|
damage: item_vec[cols - 2].parse::<u32>().unwrap(),
|
||||||
|
armor: item_vec[cols - 1].parse::<u32>().unwrap(),
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.collect::<Vec<Item>>();
|
||||||
|
match category_name {
|
||||||
|
"Weapons" => weapons = item_vec,
|
||||||
|
"Armor" => armors = item_vec,
|
||||||
|
"Rings" => rings = item_vec,
|
||||||
|
_ => panic!("Should not happen"),
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
//println!("{weapons:#?}");
|
||||||
|
//println!("{armors:#?}");
|
||||||
|
//println!("{rings:#?}");
|
||||||
|
|
||||||
|
rings.sort_by(|ring_a, ring_b| ring_a.cost.cmp(&ring_b.cost));
|
||||||
|
|
||||||
|
let choices = create_item_choices(weapons, armors, rings);
|
||||||
|
let mut highest_cost = 0;
|
||||||
|
for (weapon, armor, rings) in choices {
|
||||||
|
let mut current_player = player;
|
||||||
|
current_player.equip(weapon);
|
||||||
|
if let Some(armor) = armor {
|
||||||
|
current_player.equip(armor);
|
||||||
|
}
|
||||||
|
if !rings.is_empty() {
|
||||||
|
for ring in rings {
|
||||||
|
current_player.equip(ring);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if !current_player.wins_against(&boss) && current_player.items_value > highest_cost {
|
||||||
|
highest_cost = current_player.items_value;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
highest_cost
|
||||||
|
}
|
||||||
|
|
||||||
|
fn create_item_choices(
|
||||||
|
weapons: Vec<Item>,
|
||||||
|
armors: Vec<Item>,
|
||||||
|
rings: Vec<Item>,
|
||||||
|
) -> Vec<(Item, Option<Item>, Vec<Item>)> {
|
||||||
|
let mut choices = Vec::new();
|
||||||
|
|
||||||
|
for weapon in &weapons {
|
||||||
|
choices.push((weapon.clone(), None, vec![]));
|
||||||
|
for armor in &armors {
|
||||||
|
choices.push((weapon.clone(), Some(armor.clone()), vec![]));
|
||||||
|
for ring1 in &rings {
|
||||||
|
choices.push((weapon.clone(), Some(armor.clone()), vec![ring1.clone()]));
|
||||||
|
for ring2 in &rings {
|
||||||
|
if ring2.name == ring1.name {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
choices.push((
|
||||||
|
weapon.clone(),
|
||||||
|
Some(armor.clone()),
|
||||||
|
vec![ring1.clone(), ring2.clone()],
|
||||||
|
));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
for ring1 in &rings {
|
||||||
|
choices.push((weapon.clone(), None, vec![ring1.clone()]));
|
||||||
|
for ring2 in &rings {
|
||||||
|
if ring2.name == ring1.name {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
choices.push((weapon.clone(), None, vec![ring1.clone(), ring2.clone()]));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
choices
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Clone)]
|
||||||
|
struct Item {
|
||||||
|
name: String,
|
||||||
|
cost: u32,
|
||||||
|
damage: u32,
|
||||||
|
armor: u32,
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Default, Clone, Copy)]
|
||||||
|
struct Character {
|
||||||
|
hp: u32,
|
||||||
|
damage: u32,
|
||||||
|
armor: u32,
|
||||||
|
items_value: u32,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Character {
|
||||||
|
fn hit_damage(&self, other: &Self) -> u32 {
|
||||||
|
let damage = self.damage.saturating_sub(other.armor);
|
||||||
|
if damage > 0 {
|
||||||
|
damage
|
||||||
|
} else {
|
||||||
|
1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn wins_against(&self, other: &Self) -> bool {
|
||||||
|
let damage_to_other = self.hit_damage(other);
|
||||||
|
let mut turns_to_win = other.hp / damage_to_other;
|
||||||
|
if other.hp % damage_to_other != 0 {
|
||||||
|
turns_to_win += 1;
|
||||||
|
}
|
||||||
|
let damage_to_self = other.hit_damage(self);
|
||||||
|
let mut turns_to_lose = self.hp / damage_to_self;
|
||||||
|
if self.hp % damage_to_self != 0 {
|
||||||
|
turns_to_lose += 1;
|
||||||
|
}
|
||||||
|
turns_to_win <= turns_to_lose
|
||||||
|
}
|
||||||
|
|
||||||
|
fn equip(&mut self, item: Item) {
|
||||||
|
self.damage += item.damage;
|
||||||
|
self.armor += item.armor;
|
||||||
|
self.items_value += item.cost;
|
||||||
|
}
|
||||||
|
}
|
616
y2015/src/days/d22.rs
Normal file
616
y2015/src/days/d22.rs
Normal file
@@ -0,0 +1,616 @@
|
|||||||
|
use core::panic;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
let mut boss = Character::default();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let (attribute, value) = line.split_once(": ").unwrap();
|
||||||
|
if attribute == "Hit Points" {
|
||||||
|
boss.hp = value.parse::<u32>().unwrap();
|
||||||
|
} else if attribute == "Damage" {
|
||||||
|
boss.damage = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
let player = Character {
|
||||||
|
hp: 50,
|
||||||
|
mana: 500,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
// Initial state, nothing happened yet
|
||||||
|
let start = RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: 0,
|
||||||
|
state: State::Playing,
|
||||||
|
};
|
||||||
|
let mut smallest = u32::MAX;
|
||||||
|
let mut leafs = vec![start];
|
||||||
|
println!("start");
|
||||||
|
// Playing, Win, Loss
|
||||||
|
let mut stats = (0, 0, 0);
|
||||||
|
loop {
|
||||||
|
let current_leafs = leafs.clone();
|
||||||
|
leafs.clear();
|
||||||
|
// create potential rounds
|
||||||
|
for leaf in current_leafs {
|
||||||
|
if leaf.state == State::Playing {
|
||||||
|
for spell in Spell::get_all() {
|
||||||
|
match spell.name {
|
||||||
|
SpellID::MagicMissile | SpellID::Drain => {
|
||||||
|
leafs.push(leaf.use_spell(spell, false));
|
||||||
|
}
|
||||||
|
SpellID::Shield => {
|
||||||
|
if !leaf
|
||||||
|
.player
|
||||||
|
.status_effects
|
||||||
|
.iter()
|
||||||
|
.any(|effect| effect.name == SpellID::Shield && effect.duration > 1)
|
||||||
|
{
|
||||||
|
leafs.push(leaf.use_spell(spell, false));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
SpellID::Poison => {
|
||||||
|
if !leaf
|
||||||
|
.boss
|
||||||
|
.status_effects
|
||||||
|
.iter()
|
||||||
|
.any(|effect| effect.name == SpellID::Poison && effect.duration > 1)
|
||||||
|
{
|
||||||
|
leafs.push(leaf.use_spell(spell, false));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
SpellID::Recharge => {
|
||||||
|
if !leaf.player.status_effects.iter().any(|effect| {
|
||||||
|
effect.name == SpellID::Recharge && effect.duration > 1
|
||||||
|
}) {
|
||||||
|
leafs.push(leaf.use_spell(spell, false));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//leafs.iter().for_each(|leaf| println!("{:?}", leaf));
|
||||||
|
}
|
||||||
|
println!("leaf count: {}", leafs.len());
|
||||||
|
stats.0 = 0;
|
||||||
|
for leaf in &leafs {
|
||||||
|
if leaf.state == State::Win && leaf.spent_mana < smallest {
|
||||||
|
smallest = leaf.spent_mana;
|
||||||
|
}
|
||||||
|
match leaf.state {
|
||||||
|
State::Playing => stats.0 += 1,
|
||||||
|
State::Win => stats.1 += 1,
|
||||||
|
State::Loss => stats.2 += 1,
|
||||||
|
};
|
||||||
|
//println!(
|
||||||
|
// "player hp: {}, boss hp: {}, spent mana so far: {}",
|
||||||
|
// leaf.player.hp, leaf.boss.hp, leaf.spent_mana
|
||||||
|
//);
|
||||||
|
}
|
||||||
|
println!("Playing, win, loss: {stats:?}");
|
||||||
|
leafs.retain(|leaf| leaf.state == State::Playing && leaf.spent_mana < smallest);
|
||||||
|
if leafs.is_empty() {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
println!(" smallest: {smallest}");
|
||||||
|
}
|
||||||
|
smallest
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
let mut boss = Character::default();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let (attribute, value) = line.split_once(": ").unwrap();
|
||||||
|
if attribute == "Hit Points" {
|
||||||
|
boss.hp = value.parse::<u32>().unwrap();
|
||||||
|
} else if attribute == "Damage" {
|
||||||
|
boss.damage = value.parse::<u32>().unwrap();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
let player = Character {
|
||||||
|
hp: 50,
|
||||||
|
mana: 500,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
// Initial state, nothing happened yet
|
||||||
|
let start = RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: 0,
|
||||||
|
state: State::Playing,
|
||||||
|
};
|
||||||
|
let mut smallest = u32::MAX;
|
||||||
|
let mut leafs = vec![start];
|
||||||
|
println!("start");
|
||||||
|
// Playing, Win, Loss
|
||||||
|
let mut stats = (0, 0, 0);
|
||||||
|
loop {
|
||||||
|
let current_leafs = leafs.clone();
|
||||||
|
leafs.clear();
|
||||||
|
// create potential rounds
|
||||||
|
for leaf in current_leafs {
|
||||||
|
if leaf.state == State::Playing {
|
||||||
|
for spell in Spell::get_all() {
|
||||||
|
match spell.name {
|
||||||
|
SpellID::MagicMissile | SpellID::Drain => {
|
||||||
|
leafs.push(leaf.use_spell(spell, true));
|
||||||
|
}
|
||||||
|
SpellID::Shield => {
|
||||||
|
if !leaf
|
||||||
|
.player
|
||||||
|
.status_effects
|
||||||
|
.iter()
|
||||||
|
.any(|effect| effect.name == SpellID::Shield && effect.duration > 1)
|
||||||
|
{
|
||||||
|
leafs.push(leaf.use_spell(spell, true));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
SpellID::Poison => {
|
||||||
|
if !leaf
|
||||||
|
.boss
|
||||||
|
.status_effects
|
||||||
|
.iter()
|
||||||
|
.any(|effect| effect.name == SpellID::Poison && effect.duration > 1)
|
||||||
|
{
|
||||||
|
leafs.push(leaf.use_spell(spell, true));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
SpellID::Recharge => {
|
||||||
|
if !leaf.player.status_effects.iter().any(|effect| {
|
||||||
|
effect.name == SpellID::Recharge && effect.duration > 1
|
||||||
|
}) {
|
||||||
|
leafs.push(leaf.use_spell(spell, true));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//leafs.iter().for_each(|leaf| println!("{:?}", leaf));
|
||||||
|
}
|
||||||
|
println!("leaf count: {}", leafs.len());
|
||||||
|
stats.0 = 0;
|
||||||
|
for leaf in &leafs {
|
||||||
|
if leaf.state == State::Win && leaf.spent_mana < smallest {
|
||||||
|
smallest = leaf.spent_mana;
|
||||||
|
}
|
||||||
|
match leaf.state {
|
||||||
|
State::Playing => stats.0 += 1,
|
||||||
|
State::Win => stats.1 += 1,
|
||||||
|
State::Loss => stats.2 += 1,
|
||||||
|
};
|
||||||
|
//println!(
|
||||||
|
// "player hp: {}, boss hp: {}, spent mana so far: {}",
|
||||||
|
// leaf.player.hp, leaf.boss.hp, leaf.spent_mana
|
||||||
|
//);
|
||||||
|
}
|
||||||
|
println!("Playing, win, loss: {stats:?}");
|
||||||
|
leafs.retain(|leaf| leaf.state == State::Playing && leaf.spent_mana < smallest);
|
||||||
|
if leafs.is_empty() {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
println!(" smallest: {smallest}");
|
||||||
|
}
|
||||||
|
smallest
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||||
|
enum State {
|
||||||
|
Playing,
|
||||||
|
Win,
|
||||||
|
Loss,
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Clone)]
|
||||||
|
struct RoundNode {
|
||||||
|
player: Character,
|
||||||
|
boss: Character,
|
||||||
|
spent_mana: u32,
|
||||||
|
state: State,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl RoundNode {
|
||||||
|
fn use_spell(&self, spell: Spell, hard_mode: bool) -> RoundNode {
|
||||||
|
if self.state != State::Playing {
|
||||||
|
eprintln!("State: {:#?}", self.state);
|
||||||
|
eprintln!("spell: {spell:#?}");
|
||||||
|
panic!("State should be Playing");
|
||||||
|
}
|
||||||
|
let mut player = self.player.clone();
|
||||||
|
let mut boss = self.boss.clone();
|
||||||
|
let mut recharge_actif = false;
|
||||||
|
if hard_mode {
|
||||||
|
player.hp -= 1;
|
||||||
|
}
|
||||||
|
if player.hp == 0 {
|
||||||
|
return RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: spell.cost + self.spent_mana,
|
||||||
|
state: State::Loss,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
// Player turn
|
||||||
|
for effect in player.status_effects.iter_mut() {
|
||||||
|
if effect.name == SpellID::Recharge {
|
||||||
|
player.mana += effect.mana;
|
||||||
|
if effect.duration > 1 {
|
||||||
|
recharge_actif = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
effect.duration -= 1;
|
||||||
|
if effect.duration > 0 && effect.name == SpellID::Shield {
|
||||||
|
player.armor = effect.armor;
|
||||||
|
} else if effect.name == SpellID::Shield {
|
||||||
|
player.armor = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
for effect in boss.status_effects.iter_mut() {
|
||||||
|
boss.hp = boss.hp.saturating_sub(effect.damage);
|
||||||
|
effect.duration -= 1;
|
||||||
|
}
|
||||||
|
boss.status_effects = boss
|
||||||
|
.status_effects
|
||||||
|
.into_iter()
|
||||||
|
.filter(|&effect| effect.duration > 0)
|
||||||
|
.collect::<Vec<Spell>>();
|
||||||
|
if boss.hp == 0 {
|
||||||
|
return RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: self.spent_mana,
|
||||||
|
state: State::Win,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
player.status_effects = player
|
||||||
|
.status_effects
|
||||||
|
.into_iter()
|
||||||
|
.filter(|&effect| effect.duration > 0)
|
||||||
|
.collect::<Vec<Spell>>();
|
||||||
|
let mut dmg = 0;
|
||||||
|
if player.mana < spell.cost {
|
||||||
|
return RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: spell.cost + self.spent_mana,
|
||||||
|
state: State::Loss,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
match spell.name {
|
||||||
|
SpellID::MagicMissile => {
|
||||||
|
player.mana = player.mana.saturating_sub(spell.cost);
|
||||||
|
dmg = spell.damage;
|
||||||
|
}
|
||||||
|
SpellID::Drain => {
|
||||||
|
player.mana = player.mana.saturating_sub(spell.cost);
|
||||||
|
dmg = spell.damage;
|
||||||
|
player.hp += spell.hp;
|
||||||
|
}
|
||||||
|
SpellID::Shield => {
|
||||||
|
player.mana = player.mana.saturating_sub(spell.cost);
|
||||||
|
player.status_effects.push(spell);
|
||||||
|
player.armor = spell.armor;
|
||||||
|
}
|
||||||
|
SpellID::Poison => {
|
||||||
|
player.mana = player.mana.saturating_sub(spell.cost);
|
||||||
|
boss.status_effects.push(spell);
|
||||||
|
}
|
||||||
|
SpellID::Recharge => {
|
||||||
|
player.mana = player.mana.saturating_sub(spell.cost);
|
||||||
|
player.status_effects.push(spell);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
boss.hp = boss.hp.saturating_sub(dmg);
|
||||||
|
if boss.hp == 0 {
|
||||||
|
return RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: spell.cost + self.spent_mana,
|
||||||
|
state: State::Win,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
if player.mana == 0 && !recharge_actif {
|
||||||
|
return RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: spell.cost + self.spent_mana,
|
||||||
|
state: State::Loss,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
// Boss turn
|
||||||
|
for effect in player.status_effects.iter_mut() {
|
||||||
|
if effect.name == SpellID::Recharge {
|
||||||
|
player.mana += effect.mana;
|
||||||
|
}
|
||||||
|
effect.duration -= 1;
|
||||||
|
if effect.duration > 0 && effect.name == SpellID::Shield {
|
||||||
|
player.armor = effect.armor;
|
||||||
|
} else if effect.name == SpellID::Shield {
|
||||||
|
player.armor = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
player.status_effects = player
|
||||||
|
.status_effects
|
||||||
|
.into_iter()
|
||||||
|
.filter(|&effect| effect.duration > 0)
|
||||||
|
.collect::<Vec<Spell>>();
|
||||||
|
for effect in boss.status_effects.iter_mut() {
|
||||||
|
boss.hp = boss.hp.saturating_sub(effect.damage);
|
||||||
|
effect.duration -= 1;
|
||||||
|
}
|
||||||
|
if boss.hp == 0 {
|
||||||
|
return RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: spell.cost + self.spent_mana,
|
||||||
|
state: State::Win,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
boss.status_effects = boss
|
||||||
|
.status_effects
|
||||||
|
.into_iter()
|
||||||
|
.filter(|&effect| effect.duration > 0)
|
||||||
|
.collect::<Vec<Spell>>();
|
||||||
|
let dmg = boss.hit_damage(&player);
|
||||||
|
player.hp = player.hp.saturating_sub(dmg);
|
||||||
|
|
||||||
|
if player.hp == 0 {
|
||||||
|
return RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: spell.cost + self.spent_mana,
|
||||||
|
state: State::Loss,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: spell.cost + self.spent_mana,
|
||||||
|
state: State::Playing,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//fn get_leafs(&self) -> Vec<RoundNode> {
|
||||||
|
// let mut leafs = Vec::new();
|
||||||
|
// match self.state {
|
||||||
|
// State::Playing => {
|
||||||
|
// if self.next_rounds.is_empty() {
|
||||||
|
// return vec![self.clone()];
|
||||||
|
// }
|
||||||
|
// let mut round_leafs = Vec::new();
|
||||||
|
// for round in self.next_rounds.clone() {
|
||||||
|
// round_leafs = round.get_leafs();
|
||||||
|
// }
|
||||||
|
// leafs.append(&mut round_leafs);
|
||||||
|
// leafs
|
||||||
|
// }
|
||||||
|
// State::Win => vec![self.clone()],
|
||||||
|
// State::Loss => vec![self.clone()],
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
||||||
|
enum SpellID {
|
||||||
|
MagicMissile,
|
||||||
|
Drain,
|
||||||
|
Shield,
|
||||||
|
Poison,
|
||||||
|
Recharge,
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Clone, Copy)]
|
||||||
|
struct Spell {
|
||||||
|
name: SpellID,
|
||||||
|
hp: u32,
|
||||||
|
damage: u32,
|
||||||
|
mana: u32,
|
||||||
|
armor: u32,
|
||||||
|
duration: u32,
|
||||||
|
cost: u32,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Spell {
|
||||||
|
fn get_all() -> Vec<Spell> {
|
||||||
|
vec![
|
||||||
|
Spell {
|
||||||
|
name: SpellID::MagicMissile,
|
||||||
|
hp: 0,
|
||||||
|
damage: 4,
|
||||||
|
mana: 0,
|
||||||
|
armor: 0,
|
||||||
|
duration: 0,
|
||||||
|
cost: 53,
|
||||||
|
},
|
||||||
|
Spell {
|
||||||
|
name: SpellID::Drain,
|
||||||
|
hp: 2,
|
||||||
|
damage: 2,
|
||||||
|
mana: 0,
|
||||||
|
armor: 0,
|
||||||
|
duration: 0,
|
||||||
|
cost: 73,
|
||||||
|
},
|
||||||
|
Spell {
|
||||||
|
name: SpellID::Shield,
|
||||||
|
hp: 0,
|
||||||
|
damage: 0,
|
||||||
|
mana: 0,
|
||||||
|
armor: 7,
|
||||||
|
duration: 6,
|
||||||
|
cost: 113,
|
||||||
|
},
|
||||||
|
Spell {
|
||||||
|
name: SpellID::Poison,
|
||||||
|
hp: 0,
|
||||||
|
damage: 3,
|
||||||
|
mana: 0,
|
||||||
|
armor: 0,
|
||||||
|
duration: 6,
|
||||||
|
cost: 173,
|
||||||
|
},
|
||||||
|
Spell {
|
||||||
|
name: SpellID::Recharge,
|
||||||
|
hp: 0,
|
||||||
|
damage: 0,
|
||||||
|
mana: 101,
|
||||||
|
armor: 0,
|
||||||
|
duration: 5,
|
||||||
|
cost: 229,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Default, Clone)]
|
||||||
|
struct Character {
|
||||||
|
hp: u32,
|
||||||
|
damage: u32,
|
||||||
|
armor: u32,
|
||||||
|
mana: u32,
|
||||||
|
status_effects: Vec<Spell>,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Character {
|
||||||
|
fn hit_damage(&self, other: &Self) -> u32 {
|
||||||
|
let damage = self.damage.saturating_sub(other.armor);
|
||||||
|
if damage > 0 {
|
||||||
|
damage
|
||||||
|
} else {
|
||||||
|
1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1_1() {
|
||||||
|
let boss = Character {
|
||||||
|
hp: 13,
|
||||||
|
damage: 8,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
let player = Character {
|
||||||
|
hp: 10,
|
||||||
|
mana: 250,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
// Initial state, nothing happened yet
|
||||||
|
let start = RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: 0,
|
||||||
|
state: State::Playing,
|
||||||
|
};
|
||||||
|
let mut smallest = u32::MAX;
|
||||||
|
let mut leafs = vec![start];
|
||||||
|
println!("start");
|
||||||
|
loop {
|
||||||
|
let current_leafs = leafs.clone();
|
||||||
|
leafs.clear();
|
||||||
|
// create potential rounds
|
||||||
|
for leaf in current_leafs {
|
||||||
|
if leaf.state == State::Playing {
|
||||||
|
for spell in Spell::get_all() {
|
||||||
|
leafs.push(leaf.use_spell(spell, false));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
let mut all_done = true;
|
||||||
|
for leaf in &leafs {
|
||||||
|
if leaf.state == State::Win && leaf.spent_mana < smallest {
|
||||||
|
smallest = leaf.spent_mana;
|
||||||
|
}
|
||||||
|
if leaf.state == State::Playing {
|
||||||
|
all_done = false;
|
||||||
|
}
|
||||||
|
//println!(
|
||||||
|
// "player hp: {}, boss hp: {}, spent mana so far: {}",
|
||||||
|
// leaf.player.hp, leaf.boss.hp, leaf.spent_mana
|
||||||
|
//);
|
||||||
|
}
|
||||||
|
if all_done {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
println!(" smallest: {smallest}");
|
||||||
|
}
|
||||||
|
assert_eq!(smallest, 226);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1_2() {
|
||||||
|
let boss = Character {
|
||||||
|
hp: 14,
|
||||||
|
damage: 8,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
let player = Character {
|
||||||
|
hp: 10,
|
||||||
|
mana: 250,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
// Initial state, nothing happened yet
|
||||||
|
let start = RoundNode {
|
||||||
|
player,
|
||||||
|
boss,
|
||||||
|
spent_mana: 0,
|
||||||
|
state: State::Playing,
|
||||||
|
};
|
||||||
|
let mut smallest = u32::MAX;
|
||||||
|
let mut leafs = vec![start];
|
||||||
|
println!("start");
|
||||||
|
loop {
|
||||||
|
let current_leafs = leafs.clone();
|
||||||
|
leafs.clear();
|
||||||
|
// create potential rounds
|
||||||
|
for leaf in current_leafs {
|
||||||
|
if leaf.state == State::Playing {
|
||||||
|
for spell in Spell::get_all() {
|
||||||
|
leafs.push(leaf.use_spell(spell, false));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
let mut all_done = true;
|
||||||
|
for leaf in &leafs {
|
||||||
|
if leaf.state == State::Win && leaf.spent_mana < smallest {
|
||||||
|
smallest = leaf.spent_mana;
|
||||||
|
}
|
||||||
|
if leaf.state == State::Playing {
|
||||||
|
all_done = false;
|
||||||
|
}
|
||||||
|
//println!(
|
||||||
|
// "player hp: {}, boss hp: {}, spent mana so far: {}",
|
||||||
|
// leaf.player.hp, leaf.boss.hp, leaf.spent_mana
|
||||||
|
//);
|
||||||
|
}
|
||||||
|
if all_done {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
println!(" smallest: {smallest}");
|
||||||
|
}
|
||||||
|
assert_eq!(smallest, 641);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[allow(dead_code)]
|
||||||
|
fn init_characters() -> (Character, Character) {
|
||||||
|
let player = Character {
|
||||||
|
hp: 50,
|
||||||
|
mana: 500,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
let boss = Character {
|
||||||
|
hp: 14,
|
||||||
|
damage: 8,
|
||||||
|
..Default::default()
|
||||||
|
};
|
||||||
|
(player, boss)
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2("");
|
||||||
|
assert_eq!(result, 0);
|
||||||
|
}
|
||||||
|
}
|
155
y2015/src/days/d23.rs
Normal file
155
y2015/src/days/d23.rs
Normal file
@@ -0,0 +1,155 @@
|
|||||||
|
use core::panic;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> (i32, i32) {
|
||||||
|
let mut a = 0;
|
||||||
|
let mut b = 0;
|
||||||
|
let instructions = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| line.to_string())
|
||||||
|
.collect::<Vec<String>>();
|
||||||
|
let mut idx: i32 = 0;
|
||||||
|
loop {
|
||||||
|
if let Some(instruction) = instructions.get(idx as usize) {
|
||||||
|
let (instruction_name, instruction_action) = instruction.split_once(" ").unwrap();
|
||||||
|
match instruction_name {
|
||||||
|
"hlf" => {
|
||||||
|
if instruction_action == "a" {
|
||||||
|
a /= 2;
|
||||||
|
} else if instruction_action == "b" {
|
||||||
|
b /= 2;
|
||||||
|
}
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
"tpl" => {
|
||||||
|
if instruction_action == "a" {
|
||||||
|
a *= 3;
|
||||||
|
} else if instruction_action == "b" {
|
||||||
|
b *= 3;
|
||||||
|
}
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
"inc" => {
|
||||||
|
if instruction_action == "a" {
|
||||||
|
a += 1;
|
||||||
|
} else if instruction_action == "b" {
|
||||||
|
b += 1;
|
||||||
|
}
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
"jmp" => {
|
||||||
|
let offset = instruction_action.parse::<i32>().unwrap();
|
||||||
|
idx += offset;
|
||||||
|
}
|
||||||
|
"jie" => {
|
||||||
|
let (reg, offset) = instruction_action.split_once(", ").unwrap();
|
||||||
|
let offset: i32 = offset.parse().unwrap();
|
||||||
|
if (reg == "a" && a % 2 == 0) || (reg == "b" && b % 2 == 0) {
|
||||||
|
idx += offset;
|
||||||
|
} else {
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
"jio" => {
|
||||||
|
let (reg, offset) = instruction_action.split_once(", ").unwrap();
|
||||||
|
let offset: i32 = offset.parse().unwrap();
|
||||||
|
if (reg == "a" && a == 1) || (reg == "b" && b == 1) {
|
||||||
|
idx += offset;
|
||||||
|
} else {
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_ => panic!("Unknown instruction {instruction_name}"),
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return (a, b);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> (i32, i32) {
|
||||||
|
let mut a = 1;
|
||||||
|
let mut b = 0;
|
||||||
|
let instructions = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| line.to_string())
|
||||||
|
.collect::<Vec<String>>();
|
||||||
|
let mut idx: i32 = 0;
|
||||||
|
loop {
|
||||||
|
if let Some(instruction) = instructions.get(idx as usize) {
|
||||||
|
let (instruction_name, instruction_action) = instruction.split_once(" ").unwrap();
|
||||||
|
match instruction_name {
|
||||||
|
"hlf" => {
|
||||||
|
if instruction_action == "a" {
|
||||||
|
a /= 2;
|
||||||
|
} else if instruction_action == "b" {
|
||||||
|
b /= 2;
|
||||||
|
}
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
"tpl" => {
|
||||||
|
if instruction_action == "a" {
|
||||||
|
a *= 3;
|
||||||
|
} else if instruction_action == "b" {
|
||||||
|
b *= 3;
|
||||||
|
}
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
"inc" => {
|
||||||
|
if instruction_action == "a" {
|
||||||
|
a += 1;
|
||||||
|
} else if instruction_action == "b" {
|
||||||
|
b += 1;
|
||||||
|
}
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
"jmp" => {
|
||||||
|
let offset = instruction_action.parse::<i32>().unwrap();
|
||||||
|
idx += offset;
|
||||||
|
}
|
||||||
|
"jie" => {
|
||||||
|
let (reg, offset) = instruction_action.split_once(", ").unwrap();
|
||||||
|
let offset: i32 = offset.parse().unwrap();
|
||||||
|
if (reg == "a" && a % 2 == 0) || (reg == "b" && b % 2 == 0) {
|
||||||
|
idx += offset;
|
||||||
|
} else {
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
"jio" => {
|
||||||
|
let (reg, offset) = instruction_action.split_once(", ").unwrap();
|
||||||
|
let offset: i32 = offset.parse().unwrap();
|
||||||
|
if (reg == "a" && a == 1) || (reg == "b" && b == 1) {
|
||||||
|
idx += offset;
|
||||||
|
} else {
|
||||||
|
idx += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_ => panic!("Unknown instruction {instruction_name}"),
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return (a, b);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "inc a
|
||||||
|
jio a, +2
|
||||||
|
tpl a
|
||||||
|
inc a";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result.0, 2);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result.0, 7);
|
||||||
|
}
|
||||||
|
}
|
106
y2015/src/days/d24.rs
Normal file
106
y2015/src/days/d24.rs
Normal file
@@ -0,0 +1,106 @@
|
|||||||
|
use itertools::Itertools;
|
||||||
|
|
||||||
|
#[derive(Clone, Debug, Default)]
|
||||||
|
struct Group {
|
||||||
|
packages: Vec<usize>,
|
||||||
|
weight: usize,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Group {
|
||||||
|
fn new(packages: Vec<usize>) -> Self {
|
||||||
|
let mut group = Self::default();
|
||||||
|
for package in packages {
|
||||||
|
group.add(package);
|
||||||
|
}
|
||||||
|
group
|
||||||
|
}
|
||||||
|
|
||||||
|
fn add(&mut self, package: usize) {
|
||||||
|
self.packages.push(package);
|
||||||
|
self.weight += package;
|
||||||
|
}
|
||||||
|
|
||||||
|
fn qe(&self) -> usize {
|
||||||
|
self.packages.iter().product()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn len(&self) -> usize {
|
||||||
|
self.packages.len()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> usize {
|
||||||
|
let packages = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| line.parse::<usize>().unwrap())
|
||||||
|
.collect::<Vec<usize>>();
|
||||||
|
let group_weight = packages.iter().sum::<usize>() / 3;
|
||||||
|
let mut best_group = (usize::MAX, usize::MAX);
|
||||||
|
for k in 1..packages.len() {
|
||||||
|
let combinations = packages.clone().into_iter().combinations(k);
|
||||||
|
for combination in combinations {
|
||||||
|
let group = Group::new(combination.clone());
|
||||||
|
if group.weight == group_weight {
|
||||||
|
if group.len() < best_group.0 {
|
||||||
|
best_group = (group.len(), group.qe());
|
||||||
|
}
|
||||||
|
if group.len() == best_group.0 && group.qe() < best_group.1 {
|
||||||
|
best_group = (group.len(), group.qe());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
best_group.1
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> usize {
|
||||||
|
let packages = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| line.parse::<usize>().unwrap())
|
||||||
|
.collect::<Vec<usize>>();
|
||||||
|
let group_weight = packages.iter().sum::<usize>() / 4;
|
||||||
|
let mut best_group = (usize::MAX, usize::MAX);
|
||||||
|
for k in 1..packages.len() {
|
||||||
|
let combinations = packages.clone().into_iter().combinations(k);
|
||||||
|
for combination in combinations {
|
||||||
|
let group = Group::new(combination.clone());
|
||||||
|
if group.weight == group_weight {
|
||||||
|
if group.len() < best_group.0 {
|
||||||
|
best_group = (group.len(), group.qe());
|
||||||
|
}
|
||||||
|
if group.len() == best_group.0 && group.qe() < best_group.1 {
|
||||||
|
best_group = (group.len(), group.qe());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
best_group.1
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "1
|
||||||
|
2
|
||||||
|
3
|
||||||
|
4
|
||||||
|
5
|
||||||
|
7
|
||||||
|
8
|
||||||
|
9
|
||||||
|
10
|
||||||
|
11";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 99);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, 44);
|
||||||
|
}
|
||||||
|
}
|
38
y2015/src/days/d25.rs
Normal file
38
y2015/src/days/d25.rs
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
use utils::number::Number;
|
||||||
|
|
||||||
|
// 31562160 too high
|
||||||
|
pub fn process_part1(x: u32, y: u32) -> Number {
|
||||||
|
// the grid is actually a pyramid
|
||||||
|
// 1
|
||||||
|
// 2 3
|
||||||
|
// 4 5 6
|
||||||
|
// etc
|
||||||
|
// Num on top == 20151125
|
||||||
|
let mut current = Number::from(20151125);
|
||||||
|
let mut starting_y_idx = 2;
|
||||||
|
loop {
|
||||||
|
let mut x_idx = 1;
|
||||||
|
for y_idx in (1..=starting_y_idx).rev() {
|
||||||
|
current *= Number::from(252533);
|
||||||
|
current %= Number::from(33554393);
|
||||||
|
if x_idx == x && y_idx == y {
|
||||||
|
return current;
|
||||||
|
}
|
||||||
|
x_idx += 1;
|
||||||
|
}
|
||||||
|
starting_y_idx += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(6, 6);
|
||||||
|
assert_eq!(result, 27995004.into());
|
||||||
|
let result = process_part1(1, 2);
|
||||||
|
assert_eq!(result, 31916031.into());
|
||||||
|
}
|
||||||
|
}
|
@@ -75,7 +75,7 @@ pub fn process_part2(input: &str) -> i64 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests_3 {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
const INPUT: &str = ">
|
const INPUT: &str = ">
|
||||||
@@ -84,7 +84,7 @@ mod tests_3 {
|
|||||||
^v^v^v^v^v";
|
^v^v^v^v^v";
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn it_works() {
|
fn part1() {
|
||||||
let mut lines = INPUT.lines();
|
let mut lines = INPUT.lines();
|
||||||
let result = process_part1(lines.next().unwrap());
|
let result = process_part1(lines.next().unwrap());
|
||||||
assert_eq!(result, 2);
|
assert_eq!(result, 2);
|
||||||
|
@@ -56,14 +56,14 @@ pub fn process_part2(input: &str) -> i64 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests_4 {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
const INPUT1: &str = "abcdef";
|
const INPUT1: &str = "abcdef";
|
||||||
const INPUT2: &str = "pqrstuv";
|
const INPUT2: &str = "pqrstuv";
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn it_works() {
|
fn part1() {
|
||||||
let result = process_part1(INPUT1);
|
let result = process_part1(INPUT1);
|
||||||
assert_eq!(result, 609043);
|
assert_eq!(result, 609043);
|
||||||
let result = process_part1(INPUT2);
|
let result = process_part1(INPUT2);
|
||||||
|
@@ -76,7 +76,7 @@ pub fn process_part2(input: &str) -> i32 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests_5 {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
const INPUT1: &str = "ugknbfddgicrmopn
|
const INPUT1: &str = "ugknbfddgicrmopn
|
||||||
@@ -86,7 +86,7 @@ haegwjzuvuyypxyu
|
|||||||
dvszwmarrgswjxmb";
|
dvszwmarrgswjxmb";
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn it_works() {
|
fn part1() {
|
||||||
let result = process_part1(INPUT1);
|
let result = process_part1(INPUT1);
|
||||||
assert_eq!(result, 2);
|
assert_eq!(result, 2);
|
||||||
}
|
}
|
||||||
|
@@ -98,7 +98,7 @@ pub fn process_part2(input: &str) -> u32 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests_6 {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
const INPUT1: &str = "turn on 0,0 through 999,999";
|
const INPUT1: &str = "turn on 0,0 through 999,999";
|
||||||
@@ -106,7 +106,7 @@ mod tests_6 {
|
|||||||
const INPUT3: &str = "turn off 499,499 through 500,500";
|
const INPUT3: &str = "turn off 499,499 through 500,500";
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn it_works() {
|
fn part1() {
|
||||||
let result = process_part1(INPUT1);
|
let result = process_part1(INPUT1);
|
||||||
assert_eq!(result, 1_000_000);
|
assert_eq!(result, 1_000_000);
|
||||||
let result = process_part1(format!("{INPUT1}\n{INPUT2}").as_str());
|
let result = process_part1(format!("{INPUT1}\n{INPUT2}").as_str());
|
||||||
|
@@ -9,7 +9,7 @@ pub fn process_part1(input: &str) -> HashMap<String, u16> {
|
|||||||
instructions.insert(wire.to_string(), expression.to_string());
|
instructions.insert(wire.to_string(), expression.to_string());
|
||||||
}
|
}
|
||||||
for wire in instructions.keys() {
|
for wire in instructions.keys() {
|
||||||
set_wire(wire.to_owned(), &mut wires, &instructions);
|
set_wire(wire.to_string(), &mut wires, &instructions);
|
||||||
}
|
}
|
||||||
wires
|
wires
|
||||||
}
|
}
|
||||||
@@ -39,7 +39,7 @@ fn set_wire(
|
|||||||
if parts.len() == 2 {
|
if parts.len() == 2 {
|
||||||
let value = set_wire(parts[1].clone(), wires, instructions);
|
let value = set_wire(parts[1].clone(), wires, instructions);
|
||||||
wires.insert(wire, !value);
|
wires.insert(wire, !value);
|
||||||
return value;
|
return !value;
|
||||||
}
|
}
|
||||||
if parts.len() == 3 {
|
if parts.len() == 3 {
|
||||||
let left = match parts[0].parse::<u16>() {
|
let left = match parts[0].parse::<u16>() {
|
||||||
@@ -81,10 +81,27 @@ fn set_wire(
|
|||||||
panic!("Should not happen");
|
panic!("Should not happen");
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn process_part2(_input: &str) {}
|
pub fn process_part2(input: &str) -> HashMap<String, u16> {
|
||||||
|
let mut wires = HashMap::new();
|
||||||
|
let mut instructions = HashMap::new();
|
||||||
|
for instruction in input.lines() {
|
||||||
|
let (expression, wire) = instruction.split_once(" -> ").unwrap();
|
||||||
|
instructions.insert(wire.to_string(), expression.to_string());
|
||||||
|
}
|
||||||
|
for wire in instructions.keys() {
|
||||||
|
set_wire(wire.to_string(), &mut wires, &instructions);
|
||||||
|
}
|
||||||
|
let new_b = wires.get("a").unwrap();
|
||||||
|
instructions.insert("b".to_string(), new_b.to_string());
|
||||||
|
let mut wires = HashMap::new();
|
||||||
|
for wire in instructions.keys() {
|
||||||
|
set_wire(wire.to_string(), &mut wires, &instructions);
|
||||||
|
}
|
||||||
|
wires
|
||||||
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests_7 {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
||||||
const INPUT: &str = "123 -> x
|
const INPUT: &str = "123 -> x
|
||||||
@@ -97,7 +114,7 @@ NOT y -> i
|
|||||||
456 -> y";
|
456 -> y";
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn it_works() {
|
fn part1() {
|
||||||
let mut expected = HashMap::new();
|
let mut expected = HashMap::new();
|
||||||
expected.insert("d".to_string(), 72);
|
expected.insert("d".to_string(), 72);
|
||||||
expected.insert("e".to_string(), 507);
|
expected.insert("e".to_string(), 507);
|
||||||
|
64
y2015/src/days/d8.rs
Normal file
64
y2015/src/days/d8.rs
Normal file
@@ -0,0 +1,64 @@
|
|||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
let slashed_quote = r#"\""#;
|
||||||
|
let double_slash = r#"\\"#;
|
||||||
|
let escape = r#"\x"#;
|
||||||
|
|
||||||
|
let num_char_string_code: u32 = input.lines().map(|line| line.len() as u32).sum();
|
||||||
|
let num_char_mem: u32 = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| {
|
||||||
|
// first remove \\ and \" and replace with single random character so they count for
|
||||||
|
// one instead of 2
|
||||||
|
let line = line.to_string();
|
||||||
|
let line = line.replace(double_slash, "x");
|
||||||
|
let line = line.replace(slashed_quote, "x");
|
||||||
|
// only count what's in the quotes
|
||||||
|
let inner_quote_length = line.len() - 2;
|
||||||
|
let num_ascii_codes = line.matches(escape).count() * 3;
|
||||||
|
(inner_quote_length - num_ascii_codes) as u32
|
||||||
|
})
|
||||||
|
.sum();
|
||||||
|
num_char_string_code - num_char_mem
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
let slashed_quote = r#"\""#;
|
||||||
|
let double_slash = r#"\\"#;
|
||||||
|
let escape = r#"\x"#;
|
||||||
|
|
||||||
|
let num_char_string_code: u32 = input.lines().map(|line| line.len() as u32).sum();
|
||||||
|
let num_char_encode: u32 = input
|
||||||
|
.lines()
|
||||||
|
.map(|line| {
|
||||||
|
let line = line.to_string();
|
||||||
|
let line = line.replace(double_slash, "xxxx");
|
||||||
|
let line = line.replace(slashed_quote, "xxxx");
|
||||||
|
let line = line.replace(escape, "xxx");
|
||||||
|
line.len() as u32 + 4
|
||||||
|
})
|
||||||
|
.sum();
|
||||||
|
num_char_encode - num_char_string_code
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = r#"""
|
||||||
|
"abc"
|
||||||
|
"aaa\"aaa"
|
||||||
|
"\x27"
|
||||||
|
"#;
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 12);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, 19);
|
||||||
|
}
|
||||||
|
}
|
96
y2015/src/days/d9.rs
Normal file
96
y2015/src/days/d9.rs
Normal file
@@ -0,0 +1,96 @@
|
|||||||
|
use core::panic;
|
||||||
|
use std::collections::{HashMap, HashSet};
|
||||||
|
|
||||||
|
use utils::{math::factorial, permutation::nth_lex};
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
let mut distances = HashMap::new();
|
||||||
|
let mut locations = HashSet::new();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let (direction, distance) = line.split_once(" = ").unwrap();
|
||||||
|
let (from, to) = direction.split_once(" to ").unwrap();
|
||||||
|
let distance = distance.parse::<u32>().unwrap();
|
||||||
|
distances.insert((from.to_string(), to.to_string()), distance);
|
||||||
|
locations.insert(from.to_string());
|
||||||
|
locations.insert(to.to_string());
|
||||||
|
});
|
||||||
|
let locations = locations
|
||||||
|
.iter()
|
||||||
|
.map(|place| place.to_string())
|
||||||
|
.collect::<Vec<String>>();
|
||||||
|
let num_permutations = factorial(locations.len().try_into().unwrap());
|
||||||
|
let mut shortest = u32::MAX;
|
||||||
|
for idx in 1..=num_permutations {
|
||||||
|
let perm = nth_lex(locations.clone(), idx.try_into().unwrap()).unwrap();
|
||||||
|
let route_length = get_route_length(perm, &distances);
|
||||||
|
if route_length < shortest {
|
||||||
|
shortest = route_length;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
shortest
|
||||||
|
}
|
||||||
|
|
||||||
|
fn get_route_length(route: Vec<String>, distances: &HashMap<(String, String), u32>) -> u32 {
|
||||||
|
route
|
||||||
|
.windows(2)
|
||||||
|
.map(|pair| {
|
||||||
|
let distance = distances.get(&(pair[0].clone(), pair[1].clone()));
|
||||||
|
if let Some(distance) = distance {
|
||||||
|
return distance;
|
||||||
|
}
|
||||||
|
let distance = distances.get(&(pair[1].clone(), pair[0].clone()));
|
||||||
|
if let Some(distance) = distance {
|
||||||
|
return distance;
|
||||||
|
}
|
||||||
|
panic!("Should not happen");
|
||||||
|
})
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
let mut distances = HashMap::new();
|
||||||
|
let mut locations = HashSet::new();
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
let (direction, distance) = line.split_once(" = ").unwrap();
|
||||||
|
let (from, to) = direction.split_once(" to ").unwrap();
|
||||||
|
let distance = distance.parse::<u32>().unwrap();
|
||||||
|
distances.insert((from.to_string(), to.to_string()), distance);
|
||||||
|
locations.insert(from.to_string());
|
||||||
|
locations.insert(to.to_string());
|
||||||
|
});
|
||||||
|
let locations = locations
|
||||||
|
.iter()
|
||||||
|
.map(|place| place.to_string())
|
||||||
|
.collect::<Vec<String>>();
|
||||||
|
let num_permutations = factorial(locations.len().try_into().unwrap());
|
||||||
|
let mut longest = 0;
|
||||||
|
for idx in 1..=num_permutations {
|
||||||
|
let perm = nth_lex(locations.clone(), idx.try_into().unwrap()).unwrap();
|
||||||
|
let route_length = get_route_length(perm, &distances);
|
||||||
|
if route_length > longest {
|
||||||
|
longest = route_length;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
longest
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "London to Dublin = 464
|
||||||
|
London to Belfast = 518
|
||||||
|
Dublin to Belfast = 141";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 605);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, 982);
|
||||||
|
}
|
||||||
|
}
|
@@ -1,7 +1,25 @@
|
|||||||
pub mod d1;
|
pub mod d1;
|
||||||
|
pub mod d10;
|
||||||
|
pub mod d11;
|
||||||
|
pub mod d12;
|
||||||
|
pub mod d13;
|
||||||
|
pub mod d14;
|
||||||
|
pub mod d15;
|
||||||
|
pub mod d16;
|
||||||
|
pub mod d17;
|
||||||
|
pub mod d18;
|
||||||
|
pub mod d19;
|
||||||
pub mod d2;
|
pub mod d2;
|
||||||
|
pub mod d20;
|
||||||
|
pub mod d21;
|
||||||
|
pub mod d22;
|
||||||
|
pub mod d23;
|
||||||
|
pub mod d24;
|
||||||
|
pub mod d25;
|
||||||
pub mod d3;
|
pub mod d3;
|
||||||
pub mod d4;
|
pub mod d4;
|
||||||
pub mod d5;
|
pub mod d5;
|
||||||
pub mod d6;
|
pub mod d6;
|
||||||
pub mod d7;
|
pub mod d7;
|
||||||
|
pub mod d8;
|
||||||
|
pub mod d9;
|
||||||
|
@@ -4,3 +4,6 @@ version = "0.1.0"
|
|||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
|
md5 = { workspace = true }
|
||||||
|
utils = { workspace = true }
|
||||||
|
itertools = { workspace = true }
|
||||||
|
1
y2016/resources/1_input.txt
Normal file
1
y2016/resources/1_input.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
L5, R1, L5, L1, R5, R1, R1, L4, L1, L3, R2, R4, L4, L1, L1, R2, R4, R3, L1, R4, L4, L5, L4, R4, L5, R1, R5, L2, R1, R3, L2, L4, L4, R1, L192, R5, R1, R4, L5, L4, R5, L1, L1, R48, R5, R5, L2, R4, R4, R1, R3, L1, L4, L5, R1, L4, L2, L5, R5, L2, R74, R4, L1, R188, R5, L4, L2, R5, R2, L4, R4, R3, R3, R2, R1, L3, L2, L5, L5, L2, L1, R1, R5, R4, L3, R5, L1, L3, R4, L1, L3, L2, R1, R3, R2, R5, L3, L1, L1, R5, L4, L5, R5, R2, L5, R2, L1, L5, L3, L5, L5, L1, R1, L4, L3, L1, R2, R5, L1, L3, R4, R5, L4, L1, R5, L1, R5, R5, R5, R2, R1, R2, L5, L5, L5, R4, L5, L4, L4, R5, L2, R1, R5, L1, L5, R4, L3, R4, L2, R3, R3, R3, L2, L2, L2, L1, L4, R3, L4, L2, R2, R5, L1, R2
|
5
y2016/resources/2_input.txt
Normal file
5
y2016/resources/2_input.txt
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
LLULLLRLDLLLRLUURDDLRDLDURULRLUULUDDUDDLLLURRLDRRLDRRRLDUDLRDLRRDLLDUDUDUDRLUDUUDLLLRDURUDUULUDLRDUUUDUUDURLDUULLRDLULDUURUDRDDLDRLURLRURRDUURLRLUURURUUULLRLLULRUURLULURDLLRRUDLUDULDRDRLRULUURRDRULLRUUUDLRLDLUURRRURDLUDDRRUDRLUDRDLLLLLRULLDUDRLRRDDULDLRUURRRRRLDLDLRDURDRUUURDLRDDDDULURRRRDUURLULLLDLRULRDULRUDLRRLRDLLRLLLUDDLRDRURDDLLLLDUDRDLRURRDLRDDDLDULDRLRULUUDRRRUUULLLURRDDUULURULDURRLLULLDRURUUULRLRDRRUDRDRRDURRUUUULDRDDDUDLDDURLLRR
|
||||||
|
LDLRRRUURDLDDRLRRDLLULRULLLUDUUDUDLRULLDRUDRULLDULURDRDDLRURDDULLLLDLRDRDRDDURLURLURLUDRDDRDULULUDDRURRDLLDUURDRDDLRLLURRDLRDDULDLULURDRDLUDRRUUDULLULURRDUDRUUUDRULDLDURLRRUDURLDLRRUURRRURDLUDRLDUDRRUDUURURUDDUUDRDULRDLUDRRRLDRURLLRDDDLUDRDUDURDDDRRDDRRRLLRRDDLDDLRUURRURDLLDRLRRDLLUDRRRURURLRDRLLRLRLRULLRURLDLRRULLRRRDULUUULDRDLLURDDLDLRDRLUUDLLUDDLDRRLDLRUDRUDLLUURLLULURUDUDRLULLUDRURDDLDLDDUDLRDDRRURLRLLUDDUDRUURRURRULDRLDDRLLRRLDDURRDLDULLLURULLLRUURLRRRRUUULRLLLURRLRLRUDRDUUUDUUUDDLULLDLLLLDLDRULDRUUULDDDLURLDLRLULRUDDDDURDDLU
|
||||||
|
RURLURRDLDULLULDDDLRUULLUURLRUDRUDRRUDDLDDDDRRDLRURLRURLDDDUDDUURRDRULDRRRULRDRDDLRUDULRLURDUUDRRLDLRDRURDLDRRRRDRURUUDDDLLRDRDUDUDUDLLULURULRRLRURUULUULDDDDURULRULLRUDUURLURDUDLUDLUDRLLDUUDUULRLRLUUDRDULDULRURDRRRULRUDLRURDDULUDULLRLRURURUULLULDRURLLRRUUDDUUURRDLURUURULRDRRDDUDULRDDLUDLURURUURDRULLRDDLLRDDLDRDUDRRDLUURRLRLUURRULUDURLDDRLLURRDDDLDDRURULLDDRLUDDLRLURDUDULLRDULLLDLLUDDRUDRUDDUUDRDRULRL
|
||||||
|
RLRDRDULULUDLUDRDRLUDLDLLUDURULDDDUDLRURLLRLRLDLDRLDURDLRRURLULLULURLLDRRDRLUDRLRDLLULRULURRURURUULRDUDLLRDLRRRRRLUURDRRRDLRUDLLDLLDLRUUUDLLLDDDLRDULLRUUDDRLDDURRRDLRLRLDDDDLRDRULLUURUUDRRLLRLLRDDLLRURRRRDRULRRLLRLLLRLDRRLDDDURRURLDURUURRLRLRLDRURULLRLRUDLDUURDLLRLDLURUUUDLLRDRDDDDDDRLDRRRLRRRRURUDLDDRDLLURUDLRRLDDDLUDUDUULRDULULUDDULUUDLLLLRLDDUUULRLRDULURDURRRURRULURRRDRDLDDURDLURUDURRRDDRLRLUDLUDDLUULLDURLURDDUDDLRUUUDRLLDRURL
|
||||||
|
ULUDLLUDDULRUURDRURDUDUDLUURDDDRRLUDURURDRURRLDRDURLRLLRRDDRRDRRRUULURUDURUDULRRRRDDLDURRLRRDUDDDRLLLULDRLRLURRDUURDURRRURRDLUDUDDRLDLURRRDDRLLRDRDDRDURRRRLURRLUDDURRULRUDUDULDRUDDRULLUUULDURRRLDRULLURULLRUDLDUDDLDULDLUUDRULULDLLDRULLRUULDUDUUDRLRRLDLUULUDLLDDRLRRDDLLURURDULRRDDRURDRLRLULDLDURULLUUUDURURDLDUDDDDUUULUDLUURRULLDLRLURDLURLRLDDURRLDDRRRDUUULLUULDLLDLLDDRLRRUDLULDRLULDULULRRLRULUUURURUUURDUUDDURLLUDDRLRDDLUURRUULRDLDDRLULUULRDRURLUURDRDUURUDLRR
|
1992
y2016/resources/3_input.txt
Normal file
1992
y2016/resources/3_input.txt
Normal file
File diff suppressed because it is too large
Load Diff
980
y2016/resources/4_input.txt
Normal file
980
y2016/resources/4_input.txt
Normal file
@@ -0,0 +1,980 @@
|
|||||||
|
bkwzkqsxq-tovvilokx-nozvyiwoxd-172[fstek]
|
||||||
|
wifilzof-wbiwifuny-yhachyylcha-526[qrazx]
|
||||||
|
jvyyvzpcl-jhukf-shivyhavyf-487[zhtsi]
|
||||||
|
kwvacumz-ozilm-kivlg-kwvbiqvumvb-694[gknyw]
|
||||||
|
mvhkvbdib-kmjezxodgz-mvwwdo-omvdidib-837[dmvbi]
|
||||||
|
nzydfxpc-rclop-qwzhpc-lnbftdtetzy-171[cptzd]
|
||||||
|
vhehkyne-unggr-inkvatlbgz-813[gnehk]
|
||||||
|
tcorcikpi-hnqygt-octmgvkpi-570[nzewo]
|
||||||
|
xmtjbzidx-wvnfzo-jkzmvodjin-447[uyzlp]
|
||||||
|
willimcpy-mwupyhayl-bohn-mufym-734[stjoc]
|
||||||
|
sbejpbdujwf-cvooz-xpsltipq-961[azfnd]
|
||||||
|
jchipqat-qphzti-rjhidbtg-htgkxrt-271[thigj]
|
||||||
|
npmhcargjc-zsllw-pcqcypaf-158[mzwnx]
|
||||||
|
luxciuwncpy-jfumncw-alumm-qilembij-318[mucil]
|
||||||
|
bxaxipgn-vgpst-rpcsn-rdpixcv-htgkxrth-427[ywazt]
|
||||||
|
zekvierkzferc-tyftfcrkv-ivtvzmzex-295[evzfk]
|
||||||
|
enzcntvat-qlr-hfre-grfgvat-143[rtaef]
|
||||||
|
mvkccspson-bkllsd-nofovyzwoxd-224[oscdk]
|
||||||
|
enzcntvat-zvyvgnel-tenqr-pnaql-pbngvat-ratvarrevat-429[zymbs]
|
||||||
|
nwzekwypera-xwogap-pnwejejc-992[lkiwn]
|
||||||
|
ajmrxjlcren-ajkkrc-lxwcjrwvnwc-667[ezynd]
|
||||||
|
bxaxipgn-vgpst-hrpktcvtg-wjci-advxhixrh-661[lytku]
|
||||||
|
owshgfarwv-vqw-kzahhafy-190[ahwfv]
|
||||||
|
jqwpihizlwca-moo-twoqabqka-512[ncdyv]
|
||||||
|
apwmeclga-pyzzgr-rcaflmjmew-886[amceg]
|
||||||
|
tyepcyletzylw-ojp-wzrtdetnd-951[mxqsy]
|
||||||
|
dlhwvupglk-kfl-hjxbpzpapvu-773[nrotd]
|
||||||
|
fab-eqodqf-dmnnuf-bgdotmeuzs-612[dchyk]
|
||||||
|
qjopwxha-bhksan-skngodkl-940[kahno]
|
||||||
|
lsyrkjkbnyec-dyz-combod-cmkfoxqob-rexd-bomosfsxq-718[lktzs]
|
||||||
|
zixppfcfba-bdd-jxohbqfkd-939[sqtor]
|
||||||
|
vxupkizork-kmm-ktmotkkxotm-852[dsqjh]
|
||||||
|
excdklvo-mkxni-mykdsxq-nozkbdwoxd-952[zspmc]
|
||||||
|
bnqqnrhud-eknvdq-sqzhmhmf-391[qhndm]
|
||||||
|
gzefmnxq-otaoaxmfq-ogefayqd-eqdhuoq-716[zinwb]
|
||||||
|
qzoggwtwsr-qobrm-ghcfous-428[goqrs]
|
||||||
|
gpbepvxcv-ltpedcxots-qphzti-steadnbtci-193[ignjy]
|
||||||
|
hvbizodx-nxvqzibzm-cpio-hvmfzodib-265[hixfe]
|
||||||
|
wkqxodsm-lexxi-kxkvicsc-926[xkcis]
|
||||||
|
bknsykmdsfo-myxcewob-qbkno-oqq-zebmrkcsxq-380[utqrz]
|
||||||
|
lejkrscv-wcfnvi-kirzezex-711[ecikr]
|
||||||
|
htwwtxnaj-idj-btwpxmtu-255[itgmd]
|
||||||
|
zsxyfgqj-jll-ijufwyrjsy-931[wrpgt]
|
||||||
|
iuxxuyobk-yigbktmkx-natz-gtgreyoy-384[ygktx]
|
||||||
|
qjopwxha-xqjju-zalhkuiajp-628[esmxk]
|
||||||
|
lxaaxbren-ljwmh-anbnjalq-745[stjqy]
|
||||||
|
gokzyxsjon-zvkcdsm-qbkcc-dbksxsxq-380[tsyqk]
|
||||||
|
qzoggwtwsr-qobrm-qcohwbu-rsdofhasbh-168[obhqr]
|
||||||
|
pelbtravp-pnaql-fgbentr-325[pabel]
|
||||||
|
xzwrmkbqtm-akidmvomz-pcvb-mvoqvmmzqvo-122[mvoqz]
|
||||||
|
sbnqbhjoh-ezf-fohjoffsjoh-233[xskyb]
|
||||||
|
jyddc-yrwxefpi-fewoix-hiwmkr-412[pdekg]
|
||||||
|
fab-eqodqf-rxaiqd-xmnadmfadk-690[sicjl]
|
||||||
|
xcitgcpixdcpa-rpcsn-htgkxrth-427[stznv]
|
||||||
|
rflsjynh-rnqnyfwd-lwfij-jll-xytwflj-229[lfjnw]
|
||||||
|
zotts-wlsiayhcw-vumeyn-fuvilunils-500[ilsun]
|
||||||
|
odiih-yujbcrl-pajbb-dbna-cnbcrwp-147[bcadi]
|
||||||
|
udskkaxawv-tmffq-klgjsyw-996[tmnfc]
|
||||||
|
emixwvqhml-kpwkwtibm-wxmzibqwva-278[zomvn]
|
||||||
|
dfcxsqhwzs-dzoghwq-ufogg-zcuwghwqg-116[kmijn]
|
||||||
|
dwbcjkun-ouxfna-mnbrpw-745[nbuwa]
|
||||||
|
jchipqat-rwdrdapit-pcpanhxh-973[hglvu]
|
||||||
|
fkqbokxqflkxi-avb-zlkqxfkjbkq-861[wdnor]
|
||||||
|
wbhsfbohwcboz-foppwh-qighcasf-gsfjwqs-480[fhswb]
|
||||||
|
dzczkrip-xiruv-szfyrqriuflj-treup-kvtyefcfxp-451[rfipu]
|
||||||
|
fmsledevhsyw-fyrrc-eguymwmxmsr-698[yzoxu]
|
||||||
|
udskkaxawv-jsttal-wfyafwwjafy-840[nlkda]
|
||||||
|
sno-rdbqds-idkkxadzm-sqzhmhmf-287[lngzc]
|
||||||
|
crwwv-yxphbq-rpbo-qbpqfkd-341[bpqrw]
|
||||||
|
odiih-mhn-anjlzdrbrcrxw-563[xadcy]
|
||||||
|
jyddc-ikk-wlmttmrk-698[lmstk]
|
||||||
|
buzahisl-wshzapj-nyhzz-klzpnu-149[pjxor]
|
||||||
|
odkasqzuo-eomhqzsqd-tgzf-ymzmsqyqzf-560[frqmp]
|
||||||
|
gokzyxsjon-bkllsd-yzobkdsyxc-874[nbtmv]
|
||||||
|
excdklvo-pvygob-bocokbmr-952[tyzxa]
|
||||||
|
jvsvymbs-jovjvshal-aljouvsvnf-253[zgtdm]
|
||||||
|
hafgnoyr-qlr-erfrnepu-637[refna]
|
||||||
|
pelbtravp-sybjre-fnyrf-299[tjoim]
|
||||||
|
fodvvlilhg-gbh-vwrudjh-621[hvdgl]
|
||||||
|
kgjgrypw-epybc-bwc-bcnjmwkclr-678[smijy]
|
||||||
|
myxcewob-qbkno-mrymyvkdo-dbksxsxq-458[bkmox]
|
||||||
|
joufsobujpobm-fhh-dpoubjonfou-311[uvksy]
|
||||||
|
rflsjynh-ojqqdgjfs-ijajqturjsy-697[jqsfr]
|
||||||
|
vetllbybxw-vtgwr-kxtvjnblbmbhg-709[athym]
|
||||||
|
ajvyjprwp-ajmrxjlcren-kdwwh-lxwcjrwvnwc-433[qsaxt]
|
||||||
|
zbytomdsvo-mkxni-mykdsxq-myxdksxwoxd-952[xdmko]
|
||||||
|
esyfwlau-bwddqtwsf-suimakalagf-684[stvip]
|
||||||
|
jef-iushuj-fhezusjybu-fbqijys-whqii-huiuqhsx-582[uhijs]
|
||||||
|
tpspahyf-nyhkl-jovjvshal-bzly-alzapun-565[sdprn]
|
||||||
|
apwmeclga-hcjjwzcyl-umpiqfmn-132[shfrg]
|
||||||
|
kwtwznct-jcvvg-lmxizbumvb-148[vbcmt]
|
||||||
|
rmn-qcapcr-aylbw-umpiqfmn-366[juftv]
|
||||||
|
sorozgxe-mxgjk-hgyqkz-yzuxgmk-748[xuvst]
|
||||||
|
bkwzkqsxq-wsvsdkbi-qbkno-mkxni-mykdsxq-yzobkdsyxc-822[ksbqx]
|
||||||
|
ryexqpqhteki-vbemuh-skijecuh-iuhlysu-842[tszmj]
|
||||||
|
ikhcxvmbex-wrx-wxlbzg-501[zhqis]
|
||||||
|
lsyrkjkbnyec-mrymyvkdo-nozvyiwoxd-978[enkfi]
|
||||||
|
wdjcvuvmyjpn-mvhkvbdib-agjrzm-nojmvbz-395[tcxne]
|
||||||
|
uwtojhynqj-gfxpjy-fhvznxnynts-567[kqpvs]
|
||||||
|
iqmbazulqp-pkq-dqoquhuzs-534[ntpuq]
|
||||||
|
gntmfefwitzx-ojqqdgjfs-ijajqturjsy-385[jfqtg]
|
||||||
|
sebehvkb-fhezusjybu-zubboruqd-husuylydw-972[ytsim]
|
||||||
|
nzcczdtgp-nsznzwlep-hzcvdsza-405[yotgu]
|
||||||
|
joufsobujpobm-fhh-ufdiopmphz-675[tsymn]
|
||||||
|
cxy-bnlanc-snuuhknjw-anbnjalq-823[nabcj]
|
||||||
|
shoewudys-rkddo-huiuqhsx-374[dhsuo]
|
||||||
|
vagreangvbany-rtt-jbexfubc-403[ynepo]
|
||||||
|
aoubshwq-dzoghwq-ufogg-aobousasbh-714[oabgh]
|
||||||
|
njmjubsz-hsbef-dipdpmbuf-qvsdibtjoh-805[bdjsf]
|
||||||
|
zovldbkfz-gbiivybxk-lmboxqflkp-653[nyajo]
|
||||||
|
yknnkoera-xwogap-hkceopeyo-628[ybmzc]
|
||||||
|
nij-mywlyn-wbiwifuny-guleyncha-396[nyiwl]
|
||||||
|
ocipgvke-ecpfa-eqcvkpi-vgejpqnqia-258[jsiqz]
|
||||||
|
encuukhkgf-hnqygt-vgejpqnqia-882[dxzer]
|
||||||
|
odiih-ljwmh-anbnjalq-927[ahijl]
|
||||||
|
fkqbokxqflkxi-zxkav-ixyloxqlov-861[nxgja]
|
||||||
|
udskkaxawv-xmrrq-uzgugdslw-sfsdqkak-216[msfyx]
|
||||||
|
owshgfarwv-bwddqtwsf-kzahhafy-216[wafhd]
|
||||||
|
oaxadrgx-dmnnuf-ruzmzouzs-794[uqhse]
|
||||||
|
ziuxioqvo-akidmvomz-pcvb-zmikycqaqbqwv-616[iqvmo]
|
||||||
|
bqvvu-xqjju-opknwca-550[yzhum]
|
||||||
|
xgjougizobk-lruckx-gtgreyoy-670[nbfmk]
|
||||||
|
bxaxipgn-vgpst-uadltg-bpgztixcv-323[gptxa]
|
||||||
|
vcibutulxiom-jfumncw-alumm-nluchcha-448[ucmla]
|
||||||
|
irgyyolokj-xghhoz-uvkxgzouty-930[ogyhk]
|
||||||
|
kyelcrga-aylbw-amyrgle-umpiqfmn-782[almye]
|
||||||
|
jsvagsulanw-xdgowj-kzahhafy-138[dblcm]
|
||||||
|
ixccb-fkrfrodwh-uhdftxlvlwlrq-881[mblzw]
|
||||||
|
chnylhuncihuf-mwupyhayl-bohn-guleyncha-422[hnuyc]
|
||||||
|
irdgrxzex-treup-tfrkzex-uvgrikdvek-165[sjbnk]
|
||||||
|
xzwrmkbqtm-akidmvomz-pcvb-zmikycqaqbqwv-434[sanut]
|
||||||
|
ykhknbqh-zua-iwjwcaiajp-524[kjlio]
|
||||||
|
jlidywncfy-mwupyhayl-bohn-uwkocmcncih-916[cyhnw]
|
||||||
|
nuatmlmdpage-omzpk-eqdhuoqe-326[ljtsm]
|
||||||
|
xmrrq-kusnwfywj-zmfl-suimakalagf-684[afmkl]
|
||||||
|
foadouwbu-qvcqczohs-rsgwub-116[oubcq]
|
||||||
|
etyyx-bgnbnkzsd-kzanqzsnqx-391[pnmlv]
|
||||||
|
pinovwgz-wvnfzo-hvmfzodib-291[ovzfi]
|
||||||
|
qekrixmg-gsrwyqiv-kvehi-fewoix-ywiv-xiwxmrk-828[iwxek]
|
||||||
|
jqwpihizlwca-xtiabqk-oziaa-kcabwumz-amzdqkm-928[aizkm]
|
||||||
|
qekrixmg-jpsaiv-stivexmsrw-672[etmsq]
|
||||||
|
excdklvo-gokzyxsjon-mrymyvkdo-bomosfsxq-562[okmsx]
|
||||||
|
qczcftiz-pibbm-aobousasbh-532[zynvo]
|
||||||
|
wbhsfbohwcboz-suu-gsfjwqsg-506[bdhxv]
|
||||||
|
lxwbdvna-pajmn-ajkkrc-anlnrerwp-563[anrjk]
|
||||||
|
lsyrkjkbnyec-pvygob-cobfsmoc-900[uyrgf]
|
||||||
|
cqwdujys-sxesebqju-ixyffydw-374[nyjvi]
|
||||||
|
odiih-ouxfna-anlnrerwp-433[naior]
|
||||||
|
rzvkjiduzy-xviyt-xjvodib-vxlpdndodji-993[aousd]
|
||||||
|
ltpedcxots-qphzti-rjhidbtg-htgkxrt-453[rjlkn]
|
||||||
|
krxqjijamxdb-kdwwh-fxatbqxy-823[wctav]
|
||||||
|
froruixo-edvnhw-vwrudjh-829[rdhou]
|
||||||
|
jvyyvzpcl-jhukf-aljouvsvnf-201[uwkic]
|
||||||
|
nij-mywlyn-vumeyn-zchuhwcha-266[hnycm]
|
||||||
|
ydjuhdqjyedqb-zubboruqd-tufbeocudj-244[vmkln]
|
||||||
|
qlm-pbzobq-mixpqfz-doxpp-mrozexpfkd-575[zswni]
|
||||||
|
qvbmzvibqwvit-moo-tijwzibwzg-330[ibvwz]
|
||||||
|
pbeebfvir-fpniratre-uhag-freivprf-949[gvxlm]
|
||||||
|
wfummczcyx-jfumncw-alumm-uwkocmcncih-890[vturj]
|
||||||
|
dwbcjkun-npp-cajrwrwp-355[kstqo]
|
||||||
|
dpssptjwf-cbtlfu-vtfs-uftujoh-441[ftsuj]
|
||||||
|
vrurcjah-pajmn-npp-anbnjalq-303[tozvd]
|
||||||
|
wfruflnsl-ojqqdgjfs-xfqjx-775[fjqls]
|
||||||
|
pbafhzre-tenqr-qlr-qrirybczrag-897[yszub]
|
||||||
|
sehheiylu-rkddo-udwyduuhydw-322[qbyad]
|
||||||
|
upq-tfdsfu-cbtlfu-nbobhfnfou-103[vpxyh]
|
||||||
|
ajvyjprwp-npp-dbna-cnbcrwp-901[stevo]
|
||||||
|
bkzrrhehdc-bzmcx-bnzshmf-qdrdzqbg-833[msuya]
|
||||||
|
amlqskcp-epybc-aylbw-rcaflmjmew-730[arbyn]
|
||||||
|
wbhsfbohwcboz-dzoghwq-ufogg-gozsg-272[gobhw]
|
||||||
|
ksodcbwnsr-dfcxsqhwzs-gqojsbusf-vibh-obozmgwg-194[rwimn]
|
||||||
|
mfklstdw-usfvq-hmjuzskafy-424[ulgym]
|
||||||
|
wfruflnsl-ojqqdgjfs-qfgtwfytwd-177[xbofz]
|
||||||
|
sedikcuh-whqtu-isqludwuh-xkdj-jhqydydw-218[dhuqw]
|
||||||
|
ltpedcxots-raphhxuxts-qphzti-advxhixrh-765[jahpi]
|
||||||
|
zgmfyxypbmsq-djmucp-rcaflmjmew-548[aeoiv]
|
||||||
|
qspkfdujmf-ezf-nbobhfnfou-207[lnkrt]
|
||||||
|
fbebmtkr-zktwx-pxtihgbsxw-ietlmbv-zktll-kxlxtkva-943[hajmb]
|
||||||
|
apwmeclga-hcjjwzcyl-bctcjmnkclr-548[yxnzl]
|
||||||
|
rflsjynh-kqtbjw-btwpxmtu-177[tbjwf]
|
||||||
|
kfg-jvtivk-treup-uvgcfpdvek-373[vkefg]
|
||||||
|
upq-tfdsfu-kfmmzcfbo-nbobhfnfou-285[vsglz]
|
||||||
|
chnylhuncihuf-mwupyhayl-bohn-xypyfijgyhn-266[pwahm]
|
||||||
|
apwmeclga-zyqicr-dglylagle-886[lagce]
|
||||||
|
jlidywncfy-xsy-qilembij-188[uxjts]
|
||||||
|
jqwpihizlwca-lgm-lmaqov-954[laimq]
|
||||||
|
qcffcgwjs-foppwh-gozsg-246[fgcop]
|
||||||
|
bqxnfdmhb-rbzudmfdq-gtms-cdrhfm-287[dmbfh]
|
||||||
|
gifavtkzcv-wcfnvi-rthlzjzkzfe-763[tmniq]
|
||||||
|
uqtqbizg-ozilm-kivlg-kwibqvo-tijwzibwzg-720[qndzg]
|
||||||
|
sxdobxkdsyxkv-mkxni-bomosfsxq-848[zyubw]
|
||||||
|
qfmcusbwq-foppwh-kcfygvcd-662[cfpqw]
|
||||||
|
sehheiylu-fbqijys-whqii-skijecuh-iuhlysu-660[kdjyq]
|
||||||
|
sedikcuh-whqtu-uww-bqrehqjeho-660[dtawl]
|
||||||
|
veqtekmrk-wgezirkiv-lyrx-eguymwmxmsr-464[emrkg]
|
||||||
|
lqwhuqdwlrqdo-exqqb-uhdftxlvlwlrq-231[ydznk]
|
||||||
|
sno-rdbqds-bzmcx-otqbgzrhmf-183[gomah]
|
||||||
|
ujqgywfau-jsttal-hmjuzskafy-476[lghae]
|
||||||
|
yrwxefpi-jpsaiv-gsrxemrqirx-100[yazxo]
|
||||||
|
udglrdfwlyh-exqqb-sxufkdvlqj-569[dlqfu]
|
||||||
|
ugjjgkanw-uzgugdslw-esjcwlafy-736[rnxjs]
|
||||||
|
pdjqhwlf-sodvwlf-judvv-orjlvwlfv-673[vldfj]
|
||||||
|
xekdwvwnzkqo-fahhuxawj-ajcejaanejc-524[ajewc]
|
||||||
|
pwcvonofrcig-pibbm-fsqswjwbu-766[myazu]
|
||||||
|
tcrjjzwzvu-wcfnvi-glityrjzex-893[bkuyx]
|
||||||
|
lugjuacha-wbiwifuny-omyl-nymncha-448[mosph]
|
||||||
|
ckgvutofkj-inuiurgzk-jkvgxzsktz-228[kguzi]
|
||||||
|
ydjuhdqjyedqb-sqdto-ijehqwu-868[ozqsj]
|
||||||
|
sxdobxkdsyxkv-zvkcdsm-qbkcc-myxdksxwoxd-640[xdksc]
|
||||||
|
odkasqzuo-dmnnuf-dqmocgueufuaz-482[wfbke]
|
||||||
|
wpuvcdng-tcddkv-wugt-vguvkpi-414[hayjs]
|
||||||
|
lqwhuqdwlrqdo-edvnhw-uhfhlylqj-439[bjzye]
|
||||||
|
wpuvcdng-dwppa-ceswkukvkqp-674[mxnkj]
|
||||||
|
qzlozfhmf-bkzrrhehdc-okzrshb-fqzrr-zbpthrhshnm-365[hrzbf]
|
||||||
|
raphhxuxts-rpcsn-rdpixcv-rjhidbtg-htgkxrt-635[yozvr]
|
||||||
|
tfejldvi-xiruv-gcrjkzt-xirjj-tljkfdvi-jvimztv-321[veyxs]
|
||||||
|
ryexqpqhteki-sxesebqju-iqbui-868[qebar]
|
||||||
|
eqpuwogt-itcfg-hnqygt-tgegkxkpi-648[ywzjl]
|
||||||
|
uzfqdzmfuazmx-pkq-bgdotmeuzs-482[zmudf]
|
||||||
|
sbnqbhjoh-cbtlfu-bdrvjtjujpo-441[taquv]
|
||||||
|
gokzyxsjon-bkwzkqsxq-lexxi-bomosfsxq-354[xoskq]
|
||||||
|
oazegyqd-sdmpq-iqmbazulqp-dmnnuf-geqd-fqefuzs-456[qdefm]
|
||||||
|
dwbcjkun-ljwmh-lxjcrwp-anbnjalq-875[hoynm]
|
||||||
|
udskkaxawv-eadalsjq-yjsvw-xdgowj-klgjsyw-216[cnwyi]
|
||||||
|
surmhfwloh-exqqb-sxufkdvlqj-439[tspmq]
|
||||||
|
ksodcbwnsr-foppwh-zcuwghwqg-402[vopuk]
|
||||||
|
zsxyfgqj-hmthtqfyj-fhvznxnynts-697[fhnty]
|
||||||
|
yflexwxoalrp-yxphbq-bkdfkbbofkd-653[jzvpm]
|
||||||
|
ltpedcxots-tvv-rdcipxcbtci-557[ctdip]
|
||||||
|
slqryzjc-djmucp-qyjcq-756[cjqyd]
|
||||||
|
rgndvtcxr-qphzti-bpcpvtbtci-817[tcpbi]
|
||||||
|
ftzgxmbv-fbebmtkr-zktwx-vtgwr-vhtmbgz-lmhktzx-371[wzxvl]
|
||||||
|
htqtwkzq-hfsid-yjhmstqtld-463[rxszy]
|
||||||
|
rwcnawjcrxwju-yujbcrl-pajbb-mnenuxyvnwc-979[gkutb]
|
||||||
|
gokzyxsjon-tovvilokx-kmaescsdsyx-562[dwlah]
|
||||||
|
iutyaskx-mxgjk-lruckx-iayzuskx-ykxboik-826[kxiuy]
|
||||||
|
vhglnfxk-zktwx-yehpxk-hixktmbhgl-891[diznt]
|
||||||
|
sedikcuh-whqtu-kdijqrbu-sqdto-seqjydw-iuhlysui-790[lksjh]
|
||||||
|
jyfvnlupj-zjhclunly-obua-vwlyhapvuz-617[pirsw]
|
||||||
|
iuruxlar-sgmtkzoi-hgyqkz-zkinturume-670[qatsn]
|
||||||
|
wkqxodsm-mrymyvkdo-mecdywob-cobfsmo-250[hgarm]
|
||||||
|
odiih-kjbtnc-nwprwnnarwp-381[qpodn]
|
||||||
|
kfg-jvtivk-tyftfcrkv-kirzezex-373[srcvd]
|
||||||
|
gcfcnuls-aluxy-zotts-wuhxs-omyl-nymncha-552[clnsu]
|
||||||
|
xmtjbzidx-zbb-xpnojhzm-nzmqdxz-421[mnkio]
|
||||||
|
qjopwxha-acc-iwngapejc-160[jimst]
|
||||||
|
emixwvqhml-kivlg-kwibqvo-aitma-564[qspyb]
|
||||||
|
nvrgfezqvu-avccpsvre-cfxzjkztj-529[lmnsh]
|
||||||
|
emixwvqhml-ktiaaqnqml-xtiabqk-oziaa-ikycqaqbqwv-746[ozadu]
|
||||||
|
zhdsrqlchg-hjj-orjlvwlfv-751[hjlrv]
|
||||||
|
cybyjqho-whqtu-uww-qsgkyiyjyed-478[szxuo]
|
||||||
|
clxalrtyr-nsznzwlep-wzrtdetnd-405[lnrtz]
|
||||||
|
sgmtkzoi-yigbktmkx-natz-rghuxgzuxe-722[gktxz]
|
||||||
|
hjgbwuladw-tskcwl-sfsdqkak-502[txdsw]
|
||||||
|
yrwxefpi-hci-vigimzmrk-646[hdmzy]
|
||||||
|
hqcfqwydw-hqrryj-jusxdebewo-946[qwdeh]
|
||||||
|
wsvsdkbi-qbkno-cmkfoxqob-rexd-yzobkdsyxc-276[wptxs]
|
||||||
|
qfmcusbwq-qvcqczohs-zcuwghwqg-870[mnybx]
|
||||||
|
clxalrtyr-nsznzwlep-cpdplcns-743[rtycz]
|
||||||
|
fbebmtkr-zktwx-ktuubm-ybgtgvbgz-553[osmdy]
|
||||||
|
jvuzbtly-nyhkl-yhtwhnpun-jovjvshal-ylzlhyjo-773[hlyjn]
|
||||||
|
slqryzjc-aylbw-pcacgtgle-782[nxkri]
|
||||||
|
tfcfiwlc-wcfnvi-wzeretzex-971[smobe]
|
||||||
|
jef-iushuj-uww-qsgkyiyjyed-556[xzrwq]
|
||||||
|
crwwv-yxphbq-xkxivpfp-653[pxvwb]
|
||||||
|
hqcfqwydw-zubboruqd-husuylydw-244[lqeho]
|
||||||
|
oxmeeuruqp-qss-eqdhuoqe-534[equos]
|
||||||
|
qxdwpopgsdjh-rgndvtcxr-gpqqxi-gthtpgrw-687[gpdqr]
|
||||||
|
mybbycsfo-mrymyvkdo-bocokbmr-692[pymza]
|
||||||
|
myvybpev-oqq-yzobkdsyxc-250[sxytw]
|
||||||
|
fnjyxwrinm-kdwwh-uxprbcrlb-329[natqu]
|
||||||
|
aietsrmdih-nippcfier-gsrxemrqirx-958[iremp]
|
||||||
|
xmrrq-tmffq-vwhdgqewfl-138[fqmrw]
|
||||||
|
oqnidbshkd-bzmcx-sdbgmnknfx-599[nzdyx]
|
||||||
|
eqttqukxg-ecpfa-eqcvkpi-ewuvqogt-ugtxkeg-128[mytkp]
|
||||||
|
nchhg-ntwemz-amzdqkma-252[kmbop]
|
||||||
|
bjfutsneji-jll-zxjw-yjxynsl-775[ndbsw]
|
||||||
|
ktwbhtvmbox-lvtoxgzxk-angm-mxvaghehzr-319[ijqxb]
|
||||||
|
kyelcrga-afmamjyrc-pcqcypaf-210[acyfm]
|
||||||
|
myxcewob-qbkno-mkxni-oxqsxoobsxq-484[oxbqk]
|
||||||
|
esyfwlau-vqw-kzahhafy-788[jikae]
|
||||||
|
oqnidbshkd-eknvdq-btrsnldq-rdquhbd-391[njzml]
|
||||||
|
qjopwxha-bhksan-opknwca-888[ahkno]
|
||||||
|
udskkaxawv-jsttal-vwhdgqewfl-190[hqmnt]
|
||||||
|
excdklvo-lexxi-crszzsxq-458[uavnl]
|
||||||
|
frqvxphu-judgh-fdqgb-frdwlqj-wudlqlqj-179[bimaq]
|
||||||
|
iuruxlar-kmm-ykxboiky-852[tijpz]
|
||||||
|
tyepcyletzylw-mldvpe-lylwjdtd-509[lydet]
|
||||||
|
frqvxphu-judgh-gbh-whfkqrorjb-101[mhbes]
|
||||||
|
xqvwdeoh-edvnhw-zrunvkrs-699[zmudw]
|
||||||
|
irdgrxzex-treup-fgvirkzfej-893[fbsyn]
|
||||||
|
cxy-bnlanc-ljwmh-orwjwlrwp-771[ngpmz]
|
||||||
|
eqpuwogt-itcfg-gii-ucngu-388[hzgae]
|
||||||
|
ikhcxvmbex-cxeeruxtg-wxlbzg-553[mvnfs]
|
||||||
|
mrxivrexmsrep-fyrrc-asvowlst-854[codsq]
|
||||||
|
npmhcargjc-aylbw-qcptgacq-366[ditsg]
|
||||||
|
ftzgxmbv-ietlmbv-zktll-phkdlahi-241[ltbhi]
|
||||||
|
hqcfqwydw-tou-bewyijysi-270[hnvux]
|
||||||
|
emixwvqhml-kivlg-abwziom-590[imlvw]
|
||||||
|
pejji-nio-mecdywob-cobfsmo-926[wrjmp]
|
||||||
|
bknsykmdsfo-oqq-dbksxsxq-640[naysz]
|
||||||
|
gifavtkzcv-vxx-tfekrzedvek-789[cnwtp]
|
||||||
|
kmjezxodgz-diozmivodjivg-agjrzm-xjiovdihzio-915[yqktj]
|
||||||
|
shoewudys-vbemuh-qsgkyiyjyed-946[nqsjd]
|
||||||
|
htqtwkzq-ojqqdgjfs-rfwpjynsl-749[hryqo]
|
||||||
|
rmn-qcapcr-zyqicr-pcacgtgle-340[znstw]
|
||||||
|
bnqqnrhud-bzmcx-bnmszhmldms-729[yfetv]
|
||||||
|
surmhfwloh-gbh-rshudwlrqv-725[dsaym]
|
||||||
|
jchipqat-tvv-itrwcdadvn-505[povhu]
|
||||||
|
zgmfyxypbmsq-njyqrga-epyqq-rcaflmjmew-340[mqyae]
|
||||||
|
froruixo-exqqb-pdunhwlqj-283[nmuqd]
|
||||||
|
lnkfaypeha-xwogap-odellejc-784[ytrsz]
|
||||||
|
jlidywncfy-xsy-fuvilunils-864[ilyfn]
|
||||||
|
joufsobujpobm-dipdpmbuf-sftfbsdi-545[rwjnm]
|
||||||
|
tvsnigxmpi-gerhc-gsexmrk-eguymwmxmsr-932[pivem]
|
||||||
|
tfejldvi-xiruv-srjbvk-ivjvrity-815[vijrt]
|
||||||
|
zuv-ykixkz-yigbktmkx-natz-zkinturume-410[kzitu]
|
||||||
|
enzcntvat-pubpbyngr-qrcyblzrag-117[oywbs]
|
||||||
|
wsvsdkbi-qbkno-lkcuod-nofovyzwoxd-744[xnuqc]
|
||||||
|
wbhsfbohwcboz-foppwh-aobousasbh-246[nfsml]
|
||||||
|
uiovmbqk-jcvvg-abwziom-720[nbqaz]
|
||||||
|
etaqigpke-fag-fgrnqaogpv-674[gaefp]
|
||||||
|
ejpanjwpekjwh-nwxxep-hkceopeyo-238[bmscu]
|
||||||
|
qjopwxha-bhksan-wjwhuoeo-940[xenwh]
|
||||||
|
etyyx-bzmcx-bnzshmf-qdzbpthrhshnm-729[hbmzn]
|
||||||
|
uqtqbizg-ozilm-lgm-abwziom-356[tspmz]
|
||||||
|
excdklvo-mybbycsfo-tovvilokx-psxkxmsxq-874[axwon]
|
||||||
|
mvydjvxodqz-xviyt-xjvodib-pnzm-oznodib-187[nflym]
|
||||||
|
ixccb-zhdsrqlchg-edvnhw-xvhu-whvwlqj-465[hcvwd]
|
||||||
|
qspkfdujmf-votubcmf-tdbwfohfs-ivou-bdrvjtjujpo-181[esuzg]
|
||||||
|
fkqbokxqflkxi-qlm-pbzobq-bdd-jxohbqfkd-601[dcgym]
|
||||||
|
mtzslklcozfd-prr-nfdezxpc-dpcgtnp-301[tmnrk]
|
||||||
|
xekdwvwnzkqo-lhwopey-cnwoo-wymqeoepekj-290[rzsnk]
|
||||||
|
fubrjhqlf-sodvwlf-judvv-pdqdjhphqw-725[dfhjq]
|
||||||
|
shoewudys-zubboruqd-skijecuh-iuhlysu-608[ushbd]
|
||||||
|
zlkprjbo-doxab-zxkav-rpbo-qbpqfkd-679[bkopa]
|
||||||
|
nzcczdtgp-mldvpe-opawzjxpye-587[tkbms]
|
||||||
|
apuut-nxvqzibzm-cpio-yzkvmohzio-655[rsozd]
|
||||||
|
rgllk-ngzzk-ymdwqfuzs-300[yhzxu]
|
||||||
|
cvabijtm-jcvvg-uiviomumvb-538[ixajz]
|
||||||
|
oazegyqd-sdmpq-otaoaxmfq-pqbmdfyqzf-248[qadfm]
|
||||||
|
rtqlgevkng-fag-nqikuvkeu-960[nqdom]
|
||||||
|
bnknqetk-cxd-cdrhfm-183[mfpwa]
|
||||||
|
ohmnuvfy-wuhxs-wiuncha-lyuwkocmcncih-552[chunw]
|
||||||
|
hqtyeqsjylu-jef-iushuj-tou-fkhsxqiydw-296[isfmy]
|
||||||
|
kwtwznct-kwvacumz-ozilm-jiasmb-uiviomumvb-746[qmjyz]
|
||||||
|
qfmcusbwq-foppwh-twbobqwbu-298[bwqfo]
|
||||||
|
ykhknbqh-xqjju-owhao-472[hjtck]
|
||||||
|
dszphfojd-tdbwfohfs-ivou-mbcpsbupsz-103[sbdfo]
|
||||||
|
lahxpnwrl-ljwmh-nwprwnnarwp-641[srtpm]
|
||||||
|
ckgvutofkj-lruckx-jkvruesktz-878[zjlyk]
|
||||||
|
dyz-combod-zvkcdsm-qbkcc-nocsqx-926[yvute]
|
||||||
|
ktwbhtvmbox-wrx-nlxk-mxlmbgz-345[lsuwt]
|
||||||
|
nwilwcejc-nwxxep-zalhkuiajp-186[bznxr]
|
||||||
|
uzfqdzmfuazmx-otaoaxmfq-bgdotmeuzs-846[mzafo]
|
||||||
|
oxmeeuruqp-omzpk-oamfuzs-oazfmuzyqzf-352[ypdzg]
|
||||||
|
zhdsrqlchg-fdqgb-ghsduwphqw-361[hdgqs]
|
||||||
|
nchhg-jiasmb-amzdqkma-278[qklti]
|
||||||
|
tfiifjzmv-upv-wzeretzex-295[itvos]
|
||||||
|
eqttqukxg-ecpfa-ujkrrkpi-830[kepqr]
|
||||||
|
clotzlnetgp-mldvpe-nzyeltyxpye-145[xfpsy]
|
||||||
|
mbiyqoxsm-myvybpev-mkxni-mykdsxq-yzobkdsyxc-900[ymxbk]
|
||||||
|
plolwdub-judgh-vfdyhqjhu-kxqw-vhuylfhv-621[zqwmy]
|
||||||
|
atyzghrk-vxupkizork-jek-giwaoyozout-228[abrmv]
|
||||||
|
zotts-xsy-mufym-162[mstyf]
|
||||||
|
vhehkyne-ktuubm-mktbgbgz-293[qmytr]
|
||||||
|
kwvacumz-ozilm-zijjqb-ivitgaqa-616[fkoxt]
|
||||||
|
yaxsnlcrun-ajvyjprwp-snuuhknjw-anlnrerwp-771[zpyld]
|
||||||
|
raphhxuxts-bpvctixr-eaphixr-vgphh-bpcpvtbtci-115[phtxb]
|
||||||
|
nuatmlmdpage-odkasqzuo-qss-dqmocgueufuaz-768[umnqw]
|
||||||
|
yknnkoera-lhwopey-cnwoo-nawymqeoepekj-680[eonkw]
|
||||||
|
pybgmyargtc-aylbw-qyjcq-886[buzfp]
|
||||||
|
gzefmnxq-ngzzk-iadwetab-638[zaegn]
|
||||||
|
sbnqbhjoh-kfmmzcfbo-usbjojoh-129[acdkb]
|
||||||
|
lxaaxbren-lujbbrornm-ljwmh-lxjcrwp-mnyjacvnwc-355[yzsuk]
|
||||||
|
nchhg-lgm-nqvivkqvo-200[dystz]
|
||||||
|
plolwdub-judgh-udeelw-rshudwlrqv-335[sihdt]
|
||||||
|
wlsiayhcw-vumeyn-lymyulwb-292[zbrux]
|
||||||
|
ytu-xjhwjy-hfsid-htfynsl-qtlnxynhx-411[adxmu]
|
||||||
|
wkqxodsm-tovvilokx-ckvoc-822[uhgov]
|
||||||
|
chnylhuncihuf-vumeyn-nluchcha-500[rcbmn]
|
||||||
|
tfiifjzmv-lejkrscv-tyftfcrkv-jyzggzex-243[fjtvz]
|
||||||
|
eqpuwogt-itcfg-tcddkv-tgugctej-310[pyemh]
|
||||||
|
iuruxlar-xgsvgmotm-pkrrehkgt-xkykgxin-956[btwqp]
|
||||||
|
shoewudys-sxesebqju-qdqboiyi-894[seqbd]
|
||||||
|
zlkprjbo-doxab-gbiivybxk-pxibp-861[azyjx]
|
||||||
|
ckgvutofkj-inuiurgzk-lotgtiotm-982[qszly]
|
||||||
|
thnulapj-jshzzpmplk-jhukf-vwlyhapvuz-747[hpjlu]
|
||||||
|
pybgmyargtc-hcjjwzcyl-qcptgacq-782[bxsuc]
|
||||||
|
xgsvgmotm-vrgyzoi-mxgyy-iutzgotsktz-150[gtmoy]
|
||||||
|
laffe-yigbktmkx-natz-jkyomt-696[ktafm]
|
||||||
|
zvyvgnel-tenqr-pubpbyngr-znexrgvat-507[wfjhu]
|
||||||
|
pelbtravp-pnaql-znantrzrag-403[cbyja]
|
||||||
|
jqwpihizlwca-akidmvomz-pcvb-apqxxqvo-850[oxymv]
|
||||||
|
cvabijtm-ntwemz-twoqabqka-954[atbmq]
|
||||||
|
zixppfcfba-avb-zlkqxfkjbkq-809[zlmjc]
|
||||||
|
sebehvkb-zubboruqd-tufqhjcudj-556[budeh]
|
||||||
|
lqwhuqdwlrqdo-fdqgb-ghvljq-621[qdlgh]
|
||||||
|
qlm-pbzobq-crwwv-zxkav-zlxqfkd-rpbo-qbpqfkd-731[ciyxw]
|
||||||
|
pwcvonofrcig-gqojsbusf-vibh-qighcasf-gsfjwqs-740[csebm]
|
||||||
|
mvydjvxodqz-kmjezxodgz-kgvnodx-bmvnn-yzqzgjkhzio-239[zdovg]
|
||||||
|
kzgwomvqk-xtiabqk-oziaa-tijwzibwzg-564[menyj]
|
||||||
|
ksodcbwnsr-xszzmpsob-kcfygvcd-454[mbaod]
|
||||||
|
ejpanjwpekjwh-xwogap-hwxknwpknu-472[wpjkn]
|
||||||
|
mvydjvxodqz-hvbizodx-wpiit-hvivbzhzio-967[ivzdh]
|
||||||
|
mvydjvxodqz-mvwwdo-nzmqdxzn-681[jryzk]
|
||||||
|
enqvbnpgvir-rtt-freivprf-871[lgqrc]
|
||||||
|
hvbizodx-wpiit-kpmxcvndib-291[dyjmn]
|
||||||
|
molgbzqfib-mixpqfz-doxpp-xkxivpfp-965[pxfib]
|
||||||
|
fbebmtkr-zktwx-cxeeruxtg-nlxk-mxlmbgz-137[dckut]
|
||||||
|
luxciuwncpy-luvvcn-mbcjjcha-500[qsvzt]
|
||||||
|
apwmeclga-hcjjwzcyl-qyjcq-704[cjalq]
|
||||||
|
wpuvcdng-eqttqukxg-uecxgpigt-jwpv-cpcnauku-830[ucgpt]
|
||||||
|
iehepwnu-cnwza-fahhuxawj-pnwejejc-940[ewahj]
|
||||||
|
pbybeshy-pbeebfvir-pnaql-pbngvat-freivprf-715[uyzwp]
|
||||||
|
htsxzrjw-lwfij-ojqqdgjfs-zxjw-yjxynsl-957[iyonc]
|
||||||
|
sxdobxkdsyxkv-wsvsdkbi-qbkno-zvkcdsm-qbkcc-bomosfsxq-536[mbyan]
|
||||||
|
fruurvlyh-fkrfrodwh-uhdftxlvlwlrq-335[rflhu]
|
||||||
|
froruixo-hjj-orjlvwlfv-387[uyawn]
|
||||||
|
myvybpev-lexxi-vklybkdybi-978[ybvei]
|
||||||
|
chnylhuncihuf-vohhs-xymcah-240[yxnmh]
|
||||||
|
tagzsrsjvgmk-vqw-vwhsjlewfl-606[svwgj]
|
||||||
|
zbytomdsvo-lexxi-domrxyvyqi-250[oxydi]
|
||||||
|
qfkkj-clmmte-opgpwzaxpye-821[pekma]
|
||||||
|
lgh-kwujwl-udskkaxawv-jsttal-hmjuzskafy-320[axyrm]
|
||||||
|
irdgrxzex-nvrgfezqvu-avccpsvre-cfxzjkztj-191[sclzh]
|
||||||
|
mhi-lxvkxm-xzz-etuhktmhkr-319[rcomn]
|
||||||
|
lhkhszqx-fqzcd-dff-sdbgmnknfx-391[ugevx]
|
||||||
|
apwmeclga-aylbw-ylyjwqgq-314[izfye]
|
||||||
|
yflexwxoalrp-zlkprjbo-doxab-ciltbo-qbzeklildv-341[byclp]
|
||||||
|
cvabijtm-kwzzwaqdm-ntwemz-abwziom-252[rdmvn]
|
||||||
|
qfkkj-upwwjmply-epnsyzwzrj-899[okhgz]
|
||||||
|
jxdkbqfz-avb-zlkqxfkjbkq-861[wptxb]
|
||||||
|
gpsxdprixkt-qphzti-hwxeexcv-947[krgwe]
|
||||||
|
nij-mywlyn-wuhxs-wiuncha-lymyulwb-968[wylnu]
|
||||||
|
sbnqbhjoh-kfmmzcfbo-ufdiopmphz-987[bfhmo]
|
||||||
|
guahyncw-jfumncw-alumm-xyjfisgyhn-500[htamn]
|
||||||
|
ytu-xjhwjy-jll-ijxnls-879[duthg]
|
||||||
|
lgh-kwujwl-usfvq-ugslafy-esfsywewfl-944[ilszy]
|
||||||
|
tvsnigxmpi-tpewxmg-kveww-xiglrspskc-152[gipsw]
|
||||||
|
joufsobujpobm-cbtlfu-dvtupnfs-tfswjdf-129[fubjo]
|
||||||
|
rwcnawjcrxwju-bljenwpna-qdwc-mnyuxhvnwc-225[wncja]
|
||||||
|
qzchnzbshud-okzrshb-fqzrr-rzkdr-989[rzhbd]
|
||||||
|
qzoggwtwsr-pogysh-rsjszcdasbh-896[sghor]
|
||||||
|
gzefmnxq-dmnnuf-xmnadmfadk-326[tvuiw]
|
||||||
|
qzoggwtwsr-pibbm-zopcfohcfm-792[jsmfu]
|
||||||
|
mvydjvxodqz-xviyt-xjvodib-hvivbzhzio-369[iceny]
|
||||||
|
wkqxodsm-lkcuod-cdybkqo-224[dkocq]
|
||||||
|
veqtekmrk-ikk-wxsveki-542[keivm]
|
||||||
|
zlkprjbo-doxab-yxphbq-pqloxdb-419[ckdtm]
|
||||||
|
buzahisl-ibuuf-klzpnu-721[stjnm]
|
||||||
|
hwdtljsnh-kqtbjw-ijajqturjsy-515[plnqy]
|
||||||
|
luxciuwncpy-jfumncw-alumm-lyuwkocmcncih-474[lqpco]
|
||||||
|
tinnm-ibghopzs-rms-aobousasbh-506[sboah]
|
||||||
|
pbeebfvir-rtt-ratvarrevat-403[tdokj]
|
||||||
|
dmybmsuzs-pkq-efadmsq-300[msdqa]
|
||||||
|
ujqgywfau-tmffq-dgyaklauk-970[yxmid]
|
||||||
|
ovbunmneqbhf-enoovg-hfre-grfgvat-481[efgno]
|
||||||
|
hqfxxnknji-kzeed-uqfxynh-lwfxx-wjhjnansl-957[nxfhj]
|
||||||
|
plolwdub-judgh-edvnhw-pdqdjhphqw-985[dsxhg]
|
||||||
|
nwlddtqtpo-awldetn-rcldd-nfdezxpc-dpcgtnp-353[dnptc]
|
||||||
|
bwx-amkzmb-xzwrmkbqtm-ntwemz-amzdqkma-668[swmnl]
|
||||||
|
bqxnfdmhb-qzaahs-rdquhbdr-443[bdhqa]
|
||||||
|
egdytrixat-ide-htrgti-uadltg-steadnbtci-297[zampy]
|
||||||
|
gsrwyqiv-kvehi-gerhc-gsexmrk-erepcwmw-880[bkwts]
|
||||||
|
nsyjwsfyntsfq-gfxpjy-jslnsjjwnsl-749[lvzus]
|
||||||
|
dfcxsqhwzs-pibbm-gvwddwbu-246[dqbem]
|
||||||
|
mtzslklcozfd-ojp-fdpc-epdetyr-613[dpcef]
|
||||||
|
gbc-frperg-ohaal-erfrnepu-351[reafg]
|
||||||
|
gvaaz-cbtlfu-efqbsunfou-311[dvnmz]
|
||||||
|
ugdgjxmd-tskcwl-umklgewj-kwjnauw-892[wgjku]
|
||||||
|
iruzfrtkzmv-avccpsvre-nfibjyfg-243[jzoyc]
|
||||||
|
shoewudys-hqrryj-bqrehqjeho-296[heqrj]
|
||||||
|
hwdtljsnh-kqtbjw-htsyfnsrjsy-827[dntpc]
|
||||||
|
zilqwikbqdm-kivlg-uiviomumvb-902[imvbk]
|
||||||
|
rsvxltspi-sfnigx-wxsveki-984[sixve]
|
||||||
|
surmhfwloh-gbh-xvhu-whvwlqj-387[hwluv]
|
||||||
|
ubhatstkwhnl-yehpxk-wxlbzg-137[raqjb]
|
||||||
|
oknkvcta-itcfg-uecxgpigt-jwpv-ocpcigogpv-596[cgpio]
|
||||||
|
amjmpdsj-djmucp-nspafyqgle-470[ztpqn]
|
||||||
|
zixppfcfba-avb-abpfdk-471[abfpc]
|
||||||
|
owshgfarwv-jsttal-vwkayf-944[smcyx]
|
||||||
|
vjpwncrl-ljwmh-lxjcrwp-lxwcjrwvnwc-589[irbxq]
|
||||||
|
qvbmzvibqwvit-ziuxioqvo-lgm-amzdqkma-928[hgfln]
|
||||||
|
lxuxaodu-kjbtnc-jwjuhbrb-147[bjuxa]
|
||||||
|
etaqigpke-fag-yqtmujqr-440[qaegt]
|
||||||
|
zekvierkzferc-irdgrxzex-jtrmvexvi-ylek-rthlzjzkzfe-633[gkyzp]
|
||||||
|
mfklstdw-hdsklau-yjskk-kwjnauwk-762[vnfzg]
|
||||||
|
pkl-oaynap-fahhuxawj-oanreyao-706[mdfpn]
|
||||||
|
hwdtljsnh-hmthtqfyj-rfsfljrjsy-359[sxziu]
|
||||||
|
fab-eqodqf-ngzzk-bgdotmeuzs-144[kxags]
|
||||||
|
tagzsrsjvgmk-tskcwl-vwhsjlewfl-424[ejuah]
|
||||||
|
kzgwomvqk-jiasmb-uizsmbqvo-590[mbiko]
|
||||||
|
qjopwxha-xqjju-oanreyao-758[ubmon]
|
||||||
|
hvbizodx-xmtjbzidx-nxvqzibzm-cpio-yzkgjthzio-889[rmyqo]
|
||||||
|
iuruxlar-kmm-jkvruesktz-644[kruma]
|
||||||
|
ujqgywfau-jsttal-vwhdgqewfl-710[hbdlx]
|
||||||
|
jlidywncfy-wuhxs-wiuncha-yhachyylcha-630[hycaw]
|
||||||
|
lugjuacha-wlsiayhcw-dyffsvyuh-uhufsmcm-890[juefh]
|
||||||
|
hjgbwuladw-xdgowj-hmjuzskafy-398[wqigl]
|
||||||
|
yuxufmdk-sdmpq-pkq-etubbuzs-456[wldkg]
|
||||||
|
vcibutulxiom-dyffsvyuh-qilembij-110[jdnmz]
|
||||||
|
nzwzcqfw-clmmte-dpcgtnpd-509[cdmnp]
|
||||||
|
aczupnetwp-nlyoj-nzletyr-zapcletzyd-665[zelnp]
|
||||||
|
htsxzrjw-lwfij-wfintfhynaj-kqtbjw-knsfshnsl-983[kytzm]
|
||||||
|
enqvbnpgvir-onfxrg-qrirybczrag-611[rgnbi]
|
||||||
|
molgbzqfib-ciltbo-xkxivpfp-159[biflo]
|
||||||
|
plolwdub-judgh-fkrfrodwh-ghyhorsphqw-517[hdorw]
|
||||||
|
gzefmnxq-omzpk-oazfmuzyqzf-872[zkycu]
|
||||||
|
qjopwxha-lhwopey-cnwoo-naoawnyd-186[cvyno]
|
||||||
|
jyfvnlupj-ipvohghykvbz-jovjvshal-ylzlhyjo-435[xlenk]
|
||||||
|
ajmrxjlcren-kjbtnc-jwjuhbrb-329[klcuz]
|
||||||
|
wdjcvuvmyjpn-ezggtwzvi-jkzmvodjin-603[gmveh]
|
||||||
|
muqfedyput-fbqijys-whqii-bqrehqjeho-192[vdlge]
|
||||||
|
ktfitzbgz-xzz-ftgtzxfxgm-605[izfql]
|
||||||
|
bknsykmdsfo-oqq-wkbuodsxq-458[stifb]
|
||||||
|
slqryzjc-hcjjwzcyl-yaosgqgrgml-314[qymir]
|
||||||
|
gpewwmjmih-veffmx-xvemrmrk-126[itcvu]
|
||||||
|
rdadguja-gpqqxi-ldgzhwde-297[hnvso]
|
||||||
|
lxaaxbren-mhn-cnlqwxuxph-251[xvjuz]
|
||||||
|
xst-wigvix-fewoix-gsrxemrqirx-698[xireg]
|
||||||
|
iehepwnu-cnwza-zua-wymqeoepekj-108[sdnmj]
|
||||||
|
oknkvcta-itcfg-rncuvke-itcuu-hkpcpekpi-908[pgfbe]
|
||||||
|
enqvbnpgvir-ohaal-hfre-grfgvat-351[hsgdf]
|
||||||
|
ixccb-iorzhu-hqjlqhhulqj-647[hqcij]
|
||||||
|
apuut-agjrzm-jkzmvodjin-915[jamuz]
|
||||||
|
hqcfqwydw-rqiauj-ijehqwu-530[qwhij]
|
||||||
|
vhehkyne-ktwbhtvmbox-lvtoxgzxk-angm-kxvxbobgz-683[tsurp]
|
||||||
|
gntmfefwitzx-idj-knsfshnsl-723[fnsit]
|
||||||
|
ajvyjprwp-bljenwpna-qdwc-ujkxajcxah-563[yskxv]
|
||||||
|
joufsobujpobm-dboez-dpbujoh-mbcpsbupsz-259[bopuj]
|
||||||
|
xlrypetn-prr-nzyeltyxpye-847[yeprl]
|
||||||
|
zuv-ykixkz-xgsvgmotm-lruckx-jkvgxzsktz-696[ijlfz]
|
||||||
|
jqwpihizlwca-moo-lmxtwgumvb-798[nkzsr]
|
||||||
|
jsvagsulanw-kusnwfywj-zmfl-klgjsyw-736[ectrq]
|
||||||
|
ykhknbqh-nwxxep-nawymqeoepekj-758[cfvdy]
|
||||||
|
kzeed-gfxpjy-tujwfyntsx-385[aunmy]
|
||||||
|
slqryzjc-qaytclecp-fslr-dglylagle-184[lcyae]
|
||||||
|
laffe-vrgyzoi-mxgyy-iutzgotsktz-410[gtyzf]
|
||||||
|
gpbepvxcv-hrpktcvtg-wjci-stktadebtci-141[zoqhx]
|
||||||
|
yaxsnlcrun-lqxlxujcn-mnyuxhvnwc-641[nxclu]
|
||||||
|
tagzsrsjvgmk-kusnwfywj-zmfl-dstgjslgjq-294[gayon]
|
||||||
|
kwzzwaqdm-zijjqb-xczkpiaqvo-902[mkgjt]
|
||||||
|
mfklstdw-usfvq-ugslafy-xafsfuafy-684[fsaul]
|
||||||
|
zvyvgnel-tenqr-ovbunmneqbhf-sybjre-fgbentr-117[shfce]
|
||||||
|
emixwvqhml-akidmvomz-pcvb-amzdqkma-720[relbk]
|
||||||
|
rdggdhxkt-eaphixr-vgphh-hwxeexcv-973[xozyv]
|
||||||
|
bqvvu-zua-iwngapejc-992[nmdax]
|
||||||
|
bjfutsneji-kqtbjw-wjxjfwhm-203[irjmx]
|
||||||
|
bdavqofuxq-nmewqf-abqdmfuaze-976[vgzhc]
|
||||||
|
vdzonmhydc-okzrshb-fqzrr-rzkdr-313[rzdhk]
|
||||||
|
sawlkjevaz-oywrajcan-dqjp-wjwhuoeo-836[ajwoe]
|
||||||
|
fruurvlyh-gbh-sxufkdvlqj-413[kftmo]
|
||||||
|
fruurvlyh-sodvwlf-judvv-ghsorbphqw-569[tadzk]
|
||||||
|
sbejpbdujwf-tdbwfohfs-ivou-dpoubjonfou-103[rbqio]
|
||||||
|
oxmeeuruqp-otaoaxmfq-xasuefuoe-222[ozipy]
|
||||||
|
rdggdhxkt-qphzti-ejgrwphxcv-921[tusrb]
|
||||||
|
dkqjcbctfqwu-fag-yqtmujqr-882[kzvuf]
|
||||||
|
gzefmnxq-dmnnuf-mzmxkeue-248[menfu]
|
||||||
|
kgjgrypw-epybc-aylbw-kylyeckclr-314[mlvhs]
|
||||||
|
bwx-amkzmb-akidmvomz-pcvb-abwziom-148[nmtyw]
|
||||||
|
ckgvutofkj-sorozgxe-mxgjk-xghhoz-xkykgxin-670[gkxoh]
|
||||||
|
zhdsrqlchg-fkrfrodwh-ghsorbphqw-803[cjybd]
|
||||||
|
hvbizodx-wvnfzo-adivixdib-603[xwstz]
|
||||||
|
tvsnigxmpi-gerhc-hitpscqirx-204[icghp]
|
||||||
|
jrncbavmrq-cynfgvp-tenff-npdhvfvgvba-741[ybszn]
|
||||||
|
mbiyqoxsm-pvygob-psxkxmsxq-952[mjfnc]
|
||||||
|
gsrwyqiv-kvehi-veffmx-gywxsqiv-wivzmgi-282[bdrgj]
|
||||||
|
clxalrtyr-xtwtelcj-rclop-awldetn-rcldd-cpdplcns-847[lcdrt]
|
||||||
|
ahngzyzqcntr-bzmcx-sdbgmnknfx-287[fmyqt]
|
||||||
|
zgmfyxypbmsq-aylbw-amyrgle-bctcjmnkclr-340[mybcl]
|
||||||
|
fydelmwp-prr-nzyeltyxpye-717[gfjxa]
|
||||||
|
rnqnyfwd-lwfij-rflsjynh-wfggny-xfqjx-931[fnjwy]
|
||||||
|
zilqwikbqdm-xtiabqk-oziaa-twoqabqka-278[ftonr]
|
||||||
|
bjfutsneji-gzssd-uzwhmfxnsl-827[sfjnu]
|
||||||
|
ojk-nzxmzo-pinovwgz-agjrzm-jkzmvodjin-733[zjomn]
|
||||||
|
ygcrqpkbgf-dcumgv-fgukip-570[vmhxn]
|
||||||
|
dzczkrip-xiruv-srjbvk-jyzggzex-945[uzneh]
|
||||||
|
bkzrrhehdc-bzmcx-lzmzfdldms-287[eclvd]
|
||||||
|
ziuxioqvo-kpwkwtibm-lmxizbumvb-564[txsru]
|
||||||
|
kzgwomvqk-lgm-lmxizbumvb-122[mbgkl]
|
||||||
|
htsxzrjw-lwfij-idj-xjwanhjx-463[obdze]
|
||||||
|
gntmfefwitzx-kqtbjw-wjxjfwhm-749[qzutv]
|
||||||
|
htsxzrjw-lwfij-jll-tujwfyntsx-671[xugan]
|
||||||
|
ymszqfuo-rxaiqd-etubbuzs-118[ubqsz]
|
||||||
|
vdzonmhydc-azrjds-lzqjdshmf-989[dzhjm]
|
||||||
|
dyz-combod-bkllsd-oxqsxoobsxq-354[nrmkx]
|
||||||
|
pyknyegle-afmamjyrc-yaosgqgrgml-626[zdlfg]
|
||||||
|
oxmeeuruqp-vqxxknqmz-oazfmuzyqzf-352[rnsyt]
|
||||||
|
qjopwxha-xqjju-pnwejejc-654[jepqw]
|
||||||
|
wifilzof-jfumncw-alumm-xypyfijgyhn-604[fjerw]
|
||||||
|
vagreangvbany-enoovg-fuvccvat-533[gncot]
|
||||||
|
avw-zljyla-zjhclunly-obua-thuhnltlua-669[wathd]
|
||||||
|
ynssr-lvtoxgzxk-angm-mxvaghehzr-345[vopnm]
|
||||||
|
cvabijtm-uqtqbizg-ozilm-xtiabqk-oziaa-lmdmtwxumvb-928[imabt]
|
||||||
|
frqvxphu-judgh-sodvwlf-judvv-pdqdjhphqw-751[azovy]
|
||||||
|
qmpmxevc-kvehi-jyddc-fyrrc-qerekiqirx-282[ygmhv]
|
||||||
|
fodvvlilhg-udeelw-pdunhwlqj-153[sndmo]
|
||||||
|
gpsxdprixkt-ytaanqtpc-gthtpgrw-765[tpgar]
|
||||||
|
cvabijtm-kpwkwtibm-bmkpvwtwog-174[wbkmt]
|
||||||
|
vetllbybxw-yehpxk-wxlbzg-891[yekxl]
|
||||||
|
nzwzcqfw-nlyoj-dezclrp-275[zclnw]
|
||||||
|
qmpmxevc-kvehi-glsgspexi-gsrxemrqirx-828[exgim]
|
||||||
|
xtwtelcj-rclop-dnlgpyrpc-sfye-hzcvdsza-873[xmpon]
|
||||||
|
jrncbavmrq-pnaql-jbexfubc-793[bacjn]
|
||||||
|
ohmnuvfy-yaa-lymyulwb-266[yalmu]
|
||||||
|
nzwzcqfw-aczupnetwp-awldetn-rcldd-pyrtyppctyr-613[pctwd]
|
||||||
|
vqr-ugetgv-uecxgpigt-jwpv-rwtejcukpi-752[geptu]
|
||||||
|
tfcfiwlc-lejkrscv-upv-rthlzjzkzfe-607[tcfns]
|
||||||
|
hwdtljsnh-uqfxynh-lwfxx-knsfshnsl-229[xtngb]
|
||||||
|
iuruxlar-igtje-iayzuskx-ykxboik-930[kmghr]
|
||||||
|
xjgjmapg-ezggtwzvi-hvivbzhzio-421[gzivh]
|
||||||
|
gpbepvxcv-hrpktcvtg-wjci-hwxeexcv-349[xswrp]
|
||||||
|
tcorcikpi-eqttqukxg-gii-hkpcpekpi-622[ruxyk]
|
||||||
|
ygcrqpkbgf-ejqeqncvg-ucngu-440[gcqen]
|
||||||
|
etyyx-dff-qdbdhuhmf-729[wskto]
|
||||||
|
tfiifjzmv-upv-vexzevvizex-399[veizf]
|
||||||
|
houngfgxjuay-sorozgxe-mxgjk-jek-aykx-zkyzotm-566[aimhd]
|
||||||
|
hcd-gsqfsh-dzoghwq-ufogg-aobousasbh-714[ynfie]
|
||||||
|
foadouwbu-qobrm-qcohwbu-zopcfohcfm-792[obcfu]
|
||||||
|
ynukcajey-oywrajcan-dqjp-wjwhuoeo-680[jaowy]
|
||||||
|
rflsjynh-jll-rfsfljrjsy-489[jlfrs]
|
||||||
|
vkrhzxgbv-pxtihgbsxw-yehpxk-mktbgbgz-917[igtvy]
|
||||||
|
hjgbwuladw-tskcwl-dgyaklauk-294[aklwd]
|
||||||
|
cvabijtm-jcvvg-zmikycqaqbqwv-772[vcqab]
|
||||||
|
odiih-yujbcrl-pajbb-vjwjpnvnwc-849[jbcin]
|
||||||
|
tinnm-tzcksf-igsf-hsghwbu-220[bnamt]
|
||||||
|
pbeebfvir-wryylorna-jbexfubc-637[egouk]
|
||||||
|
xmtjbzidx-xviyt-yzqzgjkhzio-265[vxsry]
|
||||||
|
avw-zljyla-zjhclunly-obua-klwhyatlua-201[sjayl]
|
||||||
|
dfcxsqhwzs-qvcqczohs-fsgsofqv-246[dosrp]
|
||||||
|
rzvkjiduzy-xviyt-xjvodib-kpmxcvndib-291[cwzla]
|
||||||
|
gcfcnuls-aluxy-mwupyhayl-bohn-wihnuchgyhn-968[hnuyc]
|
||||||
|
dyz-combod-lsyrkjkbnyec-bkllsd-domrxyvyqi-328[vtxzd]
|
||||||
|
fruurvlyh-mhoobehdq-dftxlvlwlrq-907[jlves]
|
||||||
|
mrxivrexmsrep-gerhc-gsexmrk-tyvglewmrk-152[wzuly]
|
||||||
|
votubcmf-gmpxfs-pqfsbujpot-883[fpbmo]
|
||||||
|
bljenwpna-qdwc-anbnjalq-329[lcwmy]
|
||||||
|
xekdwvwnzkqo-ydkykhwpa-wjwhuoeo-550[toavy]
|
||||||
|
yhkpvhjapcl-yhiipa-jbzavtly-zlycpjl-201[lpyah]
|
||||||
|
xjinphzm-bmvyz-wvnfzo-nzmqdxzn-681[ykfxe]
|
||||||
|
pbeebfvir-rtt-ybtvfgvpf-507[bftve]
|
||||||
|
gvcskirmg-ikk-hizipstqirx-750[iyquj]
|
||||||
|
yhwooebeaz-lhwopey-cnwoo-oanreyao-108[tmuag]
|
||||||
|
wlqqp-jtrmvexvi-ylek-nfibjyfg-581[tnrhf]
|
||||||
|
tfiifjzmv-avccpsvre-jyzggzex-477[mvnjr]
|
||||||
|
xjmmjndqz-zbb-yzndbi-811[bzdjm]
|
||||||
|
qjopwxha-xwogap-nayaerejc-160[isjqz]
|
||||||
|
qzlozfhmf-azrjds-knfhrshbr-573[dfmys]
|
||||||
|
vhglnfxk-zktwx-vetllbybxw-vtgwr-vhtmbgz-ybgtgvbgz-761[gbtvl]
|
||||||
|
etaqigpke-ecpfa-eqcvkpi-cpcnauku-336[eyxtb]
|
||||||
|
lqwhuqdwlrqdo-fdqgb-frdwlqj-zrunvkrs-933[tvijl]
|
||||||
|
gvcskirmg-tvsnigxmpi-gerhc-gsexmrk-wlmttmrk-828[szawg]
|
||||||
|
irdgrxzex-kfg-jvtivk-wcfnvi-jyzggzex-269[givxz]
|
||||||
|
cqwdujys-sqdto-iqbui-270[siyeh]
|
||||||
|
bnqqnrhud-bgnbnkzsd-trdq-sdrshmf-807[dnbqr]
|
||||||
|
rgndvtcxr-hrpktcvtg-wjci-prfjxhxixdc-193[yjsht]
|
||||||
|
qekrixmg-hci-xvemrmrk-282[mreik]
|
||||||
|
xcitgcpixdcpa-snt-apqdgpidgn-349[mfywv]
|
||||||
|
wkqxodsm-pvygob-wkbuodsxq-978[ysamp]
|
||||||
|
aoubshwq-qvcqczohs-kcfygvcd-558[ytvls]
|
||||||
|
tyepcyletzylw-qwzhpc-opalcexpye-301[gamdn]
|
||||||
|
tfcfiwlc-treup-uvjzxe-607[nrthm]
|
||||||
|
ubhatstkwhnl-lvtoxgzxk-angm-inkvatlbgz-865[tagkl]
|
||||||
|
wihmogyl-aluxy-yaa-qilembij-890[emvct]
|
||||||
|
bxaxipgn-vgpst-ltpedcxots-gpqqxi-hidgpvt-245[pgtxi]
|
||||||
|
jfifqxov-doxab-mixpqfz-doxpp-obpbxoze-107[ghpyi]
|
||||||
|
gvaaz-dpssptjwf-sbccju-fohjoffsjoh-675[pfzwa]
|
||||||
|
gzefmnxq-eomhqzsqd-tgzf-efadmsq-378[qefmz]
|
||||||
|
emixwvqhml-kivlg-zmkmqdqvo-876[dcfin]
|
||||||
|
fodvvlilhg-fdqgb-frqwdlqphqw-725[qdflg]
|
||||||
|
laffe-pkrrehkgt-rumoyzoiy-670[dyjut]
|
||||||
|
egdytrixat-qphzti-tcvxcttgxcv-245[tcxgi]
|
||||||
|
htqtwkzq-wfintfhynaj-xhfajsljw-mzsy-jslnsjjwnsl-645[eynzi]
|
||||||
|
vrurcjah-pajmn-npp-mnyuxhvnwc-563[npach]
|
||||||
|
ejpanjwpekjwh-acc-klanwpekjo-576[jaekp]
|
||||||
|
kwvacumz-ozilm-kpwkwtibm-uizsmbqvo-876[mikwz]
|
||||||
|
hjgbwuladw-xdgowj-esfsywewfl-866[byzdm]
|
||||||
|
pbybeshy-wryylorna-npdhvfvgvba-351[stmxy]
|
||||||
|
qjopwxha-ywjzu-hkceopeyo-654[tysoa]
|
||||||
|
lhkhszqx-fqzcd-dff-vnqjrgno-417[fqdhn]
|
||||||
|
rgllk-otaoaxmfq-fdmuzuzs-768[vkqac]
|
||||||
|
ohmnuvfy-xsy-omyl-nymncha-214[hmtfs]
|
||||||
|
enzcntvat-cynfgvp-tenff-nanylfvf-455[cuimh]
|
||||||
|
sedikcuh-whqtu-sehheiylu-tou-bqrehqjeho-868[ydaux]
|
||||||
|
tyepcyletzylw-ojp-opalcexpye-145[wciks]
|
||||||
|
udpsdjlqj-hjj-frqwdlqphqw-309[gbpcz]
|
||||||
|
eqpuwogt-itcfg-lgnnadgcp-vtckpkpi-388[gpcti]
|
||||||
|
rkpqxyib-pzxsbkdbo-erkq-zrpqljbo-pbosfzb-133[bpkoq]
|
||||||
|
kdijqrbu-sxesebqju-tufqhjcudj-114[tdbva]
|
||||||
|
gsvvswmzi-wgezirkiv-lyrx-irkmriivmrk-412[twsrk]
|
||||||
|
ucynmlgxcb-qaytclecp-fslr-amlryglkclr-704[lcrya]
|
||||||
|
xst-wigvix-veffmx-wxsveki-100[ocvmr]
|
||||||
|
surmhfwloh-vfdyhqjhu-kxqw-frqwdlqphqw-829[hqwfd]
|
||||||
|
xmrrq-usfvq-esfsywewfl-528[alidm]
|
||||||
|
zhdsrqlchg-lqwhuqdwlrqdo-sodvwlf-judvv-ghsorbphqw-777[rtnmj]
|
||||||
|
egdytrixat-xcitgcpixdcpa-rwdrdapit-uxcpcrxcv-245[cdabn]
|
||||||
|
yrwxefpi-ikk-gywxsqiv-wivzmgi-152[iwgkv]
|
||||||
|
qcffcgwjs-foppwh-obozmgwg-558[zotsu]
|
||||||
|
veqtekmrk-gerhc-gsexmrk-hitpscqirx-568[nczdq]
|
||||||
|
gzefmnxq-pkq-pqbmdfyqzf-794[jxrmh]
|
||||||
|
eadalsjq-yjsvw-usfvq-ugslafy-ugflsafewfl-632[fsalu]
|
||||||
|
esyfwlau-usfvq-ugslafy-vwhdgqewfl-684[flsuw]
|
||||||
|
ktfitzbgz-fbebmtkr-zktwx-utldxm-wxlbzg-683[afwhg]
|
||||||
|
wihmogyl-aluxy-vohhs-uwkocmcncih-292[wzryd]
|
||||||
|
bkzrrhehdc-idkkxadzm-lzmzfdldms-677[oxwvn]
|
||||||
|
clxalrtyr-qwzhpc-lnbftdtetzy-249[zryvn]
|
||||||
|
rgllk-fab-eqodqf-vqxxknqmz-pqbxakyqzf-222[qfkxa]
|
||||||
|
xjinphzm-bmvyz-xviyt-mzxzdqdib-603[xnhfs]
|
||||||
|
htsxzrjw-lwfij-hmthtqfyj-wjfhvznxnynts-385[zreuy]
|
||||||
|
myvybpev-gokzyxsjon-oqq-nozvyiwoxd-692[iyzuj]
|
||||||
|
hcd-gsqfsh-pogysh-gvwddwbu-480[mysuk]
|
||||||
|
hcd-gsqfsh-foppwh-rsgwub-428[kvtfs]
|
||||||
|
frqvxphu-judgh-exqqb-uhvhdufk-621[wtgmn]
|
||||||
|
vhglnfxk-zktwx-vahvhetmx-vhgmtbgfxgm-345[hnamj]
|
||||||
|
tagzsrsjvgmk-usfvq-ugslafy-ugflsafewfl-892[yckbv]
|
||||||
|
joufsobujpobm-gmpxfs-vtfs-uftujoh-233[foujs]
|
||||||
|
zsxyfgqj-ojqqdgjfs-zxjw-yjxynsl-593[jqsxy]
|
||||||
|
bnknqetk-atmmx-qdzbpthrhshnm-131[ecnmt]
|
||||||
|
hmsdqmzshnmzk-dff-sqzhmhmf-859[dnxcz]
|
||||||
|
hqtyeqsjylu-tou-udwyduuhydw-348[uydhq]
|
||||||
|
ktiaaqnqml-kpwkwtibm-zmikycqaqbqwv-772[tlrsg]
|
||||||
|
nzydfxpc-rclop-mtzslklcozfd-mfyyj-nfdezxpc-dpcgtnp-951[cpdfz]
|
||||||
|
ckgvutofkj-hatte-gtgreyoy-644[tgeko]
|
||||||
|
iwcjapey-zua-paydjkhkcu-628[hntmg]
|
||||||
|
bnknqetk-okzrshb-fqzrr-trdq-sdrshmf-729[tuzoy]
|
||||||
|
qmpmxevc-kvehi-yrwxefpi-glsgspexi-wlmttmrk-828[hsyvf]
|
||||||
|
amjmpdsj-njyqrga-epyqq-qcptgacq-106[bhysd]
|
||||||
|
dwbcjkun-ljwmh-mnyuxhvnwc-641[wuyrz]
|
||||||
|
gspsvjyp-jpsaiv-hiwmkr-854[zthel]
|
||||||
|
gsrwyqiv-kvehi-gerhc-stivexmsrw-750[whgse]
|
||||||
|
xjgjmapg-wpiit-ozxcijgjbt-889[ytsop]
|
||||||
|
xgjougizobk-kmm-rghuxgzuxe-280[cwrty]
|
||||||
|
zovldbkfz-oxjmxdfkd-oxyyfq-ixyloxqlov-653[snkwb]
|
||||||
|
qczcftiz-qvcqczohs-gsfjwqsg-142[cqszf]
|
||||||
|
krxqjijamxdb-mhn-ldbcxvna-bnaerln-771[ravbt]
|
||||||
|
pybgmyargtc-bwc-bcqgel-860[bcgya]
|
||||||
|
wyvqljapsl-jovjvshal-shivyhavyf-773[vahjl]
|
||||||
|
pbafhzre-tenqr-onfxrg-bcrengvbaf-221[zyaro]
|
||||||
|
glrcplyrgmlyj-bwc-pcqcypaf-132[clpyg]
|
||||||
|
dpmpsgvm-dboez-dpbujoh-tfswjdft-545[bdmzf]
|
||||||
|
dkqjcbctfqwu-rncuvke-itcuu-cpcnauku-700[cuknq]
|
||||||
|
ajmrxjlcren-yujbcrl-pajbb-anbnjalq-459[yslvg]
|
||||||
|
oazegyqd-sdmpq-bxmefuo-sdmee-fqotzaxask-586[vfmnu]
|
||||||
|
ugdgjxmd-jsttal-ksdwk-632[hfjix]
|
||||||
|
aietsrmdih-gvcskirmg-tpewxmg-kveww-vigimzmrk-412[kfcim]
|
||||||
|
drxevkzt-jtrmvexvi-ylek-uvgcfpdvek-685[vekdr]
|
||||||
|
excdklvo-bkllsd-nozvyiwoxd-250[dlokv]
|
||||||
|
uwtojhynqj-hfsid-wjxjfwhm-281[fqsmx]
|
||||||
|
plolwdub-judgh-udeelw-uhfhlylqj-205[ludhe]
|
||||||
|
oqnidbshkd-dff-zmzkxrhr-729[cvlkx]
|
||||||
|
bknsykmdsfo-tovvilokx-bomosfsxq-328[boqly]
|
||||||
|
dpotvnfs-hsbef-qspkfdujmf-cvooz-tijqqjoh-961[zmnyi]
|
||||||
|
gspsvjyp-fyrrc-gsrxemrqirx-490[rsgpx]
|
||||||
|
gifavtkzcv-szfyrqriuflj-wcfnvi-uvmvcfgdvek-139[zadfj]
|
||||||
|
gsrwyqiv-kvehi-wgezirkiv-lyrx-wxsveki-490[alpzb]
|
||||||
|
ykhknbqh-ydkykhwpa-zalhkuiajp-862[khayp]
|
||||||
|
dmybmsuzs-yuxufmdk-sdmpq-bxmefuo-sdmee-fqotzaxask-586[nwikx]
|
||||||
|
nwzekwypera-bhksan-nayaerejc-940[xnmta]
|
||||||
|
wrs-vhfuhw-hjj-zrunvkrs-283[hrjsu]
|
||||||
|
ajyqqgdgcb-pyzzgr-amlryglkclr-782[lozts]
|
||||||
|
ohmnuvfy-jfumncw-alumm-womnigyl-mylpcwy-110[mqrgd]
|
||||||
|
foadouwbu-suu-obozmgwg-792[hgkuj]
|
||||||
|
wdjcvuvmyjpn-ytz-yzkgjthzio-109[jyztv]
|
||||||
|
ucynmlgxcb-pyzzgr-qfgnngle-210[iftry]
|
||||||
|
ymszqfuo-omzpk-oamfuzs-pqhqxabyqzf-872[qzfmo]
|
||||||
|
clotzlnetgp-ojp-opawzjxpye-769[pnhtz]
|
||||||
|
mhi-lxvkxm-yehpxk-ftgtzxfxgm-657[etajx]
|
||||||
|
surmhfwloh-fkrfrodwh-uhfhlylqj-699[rkslj]
|
||||||
|
iruzfrtkzmv-tyftfcrkv-kirzezex-841[emztq]
|
||||||
|
bdavqofuxq-nmewqf-ogefayqd-eqdhuoq-352[jpmyv]
|
||||||
|
bdavqofuxq-otaoaxmfq-xasuefuoe-326[aofqu]
|
||||||
|
gpsxdprixkt-tvv-ldgzhwde-219[dgptv]
|
||||||
|
pbeebfvir-rtt-bcrengvbaf-897[enlaq]
|
||||||
|
jchipqat-gpqqxi-bpgztixcv-375[cnqyt]
|
||||||
|
glrcplyrgmlyj-qaytclecp-fslr-pcqcypaf-574[clpyr]
|
||||||
|
pejji-oqq-vyqscdsmc-640[qcjsd]
|
||||||
|
houngfgxjuay-yigbktmkx-natz-xkykgxin-774[mszcw]
|
||||||
|
ltpedcxots-jchipqat-gpqqxi-bpcpvtbtci-219[isgfv]
|
||||||
|
gifavtkzcv-tyftfcrkv-drerxvdvek-659[vbdyz]
|
||||||
|
vjpwncrl-mhn-orwjwlrwp-641[wrjln]
|
||||||
|
vjpwncrl-ouxfna-bcxajpn-511[ydzfw]
|
||||||
|
rzvkjiduzy-xviyt-xjvodib-adivixdib-187[idvxb]
|
||||||
|
tinnm-suu-twbobqwbu-272[datjf]
|
||||||
|
apuut-xviyt-vxlpdndodji-941[zrtso]
|
||||||
|
jxdkbqfz-zixppfcfba-mixpqfz-doxpp-jxohbqfkd-705[fpxbd]
|
||||||
|
zilqwikbqdm-lgm-kwvbiqvumvb-876[bqpme]
|
||||||
|
jyddc-wgezirkiv-lyrx-wxsveki-256[sjntv]
|
||||||
|
ahngzyzqcntr-qzaahs-zbpthrhshnm-963[fzvai]
|
||||||
|
ksodcbwnsr-qfmcusbwq-suu-qighcasf-gsfjwqs-350[wyezk]
|
||||||
|
atyzghrk-igtje-iugzotm-jkyomt-462[ksuli]
|
||||||
|
dwbcjkun-ajmrxjlcren-yujbcrl-pajbb-nwprwnnarwp-563[tjsqg]
|
||||||
|
aoubshwq-dzoghwq-ufogg-aofyshwbu-896[hwcmz]
|
||||||
|
apwmeclga-npmhcargjc-njyqrga-epyqq-rpyglgle-340[dgtsc]
|
||||||
|
apwmeclga-aylbw-amyrgle-dglylagle-210[iumzy]
|
||||||
|
ydjuhdqjyedqb-rkddo-sedjqydcudj-738[ycbmx]
|
||||||
|
iuxxuyobk-xgjougizobk-pkrrehkgt-sgtgmksktz-644[pzsmw]
|
||||||
|
bnmrtldq-fqzcd-bgnbnkzsd-vnqjrgno-521[nbdqg]
|
||||||
|
wfruflnsl-gzssd-wjhjnansl-177[wtmsg]
|
||||||
|
yhwooebeaz-ywjzu-klanwpekjo-680[eowaj]
|
||||||
|
pynffvsvrq-cynfgvp-tenff-ernpdhvfvgvba-663[vbduy]
|
||||||
|
zilqwikbqdm-ntwemz-uizsmbqvo-356[yhenq]
|
||||||
|
jvsvymbs-zjhclunly-obua-jvuahputlua-721[uajlv]
|
||||||
|
fhezusjybu-rqiauj-tufbeocudj-400[ecamb]
|
||||||
|
ftzgxmbv-wrx-xgzbgxxkbgz-293[xgbzf]
|
||||||
|
chnylhuncihuf-xsy-xypyfijgyhn-578[jigcy]
|
||||||
|
vhkkhlbox-pxtihgbsxw-cxeeruxtg-wxlbzg-111[hsuty]
|
||||||
|
foadouwbu-tzcksf-gozsg-246[ofgsu]
|
||||||
|
xzwrmkbqtm-moo-nqvivkqvo-434[moqvk]
|
||||||
|
gvaaz-cvooz-dpoubjonfou-415[mcnzb]
|
||||||
|
pbafhzre-tenqr-enoovg-grpuabybtl-169[bktjl]
|
||||||
|
uwtojhynqj-gzssd-ywfnsnsl-723[phguv]
|
||||||
|
dlhwvupglk-zjhclunly-obua-klwhyatlua-227[luahk]
|
||||||
|
vhkkhlbox-vhehkyne-vahvhetmx-ybgtgvbgz-215[hvbeg]
|
||||||
|
qlm-pbzobq-gbiivybxk-lmboxqflkp-809[blqik]
|
||||||
|
forwcoqhwjs-qvcqczohs-ghcfous-792[mtuqn]
|
||||||
|
eqpuwogt-itcfg-dwppa-fgrnqaogpv-570[gpafo]
|
||||||
|
lxuxaodu-bljenwpna-qdwc-jwjuhbrb-121[rbqfd]
|
||||||
|
ykhknbqh-xqjju-oanreyao-680[ahjkn]
|
||||||
|
ugfkmewj-yjsvw-hdsklau-yjskk-kzahhafy-918[kahjs]
|
||||||
|
gbc-frperg-fpniratre-uhag-fnyrf-897[dskta]
|
||||||
|
myxcewob-qbkno-lexxi-wkxkqowoxd-770[spdoc]
|
||||||
|
cqwdujys-fbqijys-whqii-huiuqhsx-998[uhebs]
|
||||||
|
ckgvutofkj-igtje-iugzotm-rghuxgzuxe-774[gutei]
|
||||||
|
excdklvo-lexxi-psxkxmsxq-302[ypsmx]
|
||||||
|
mbiyqoxsm-dyz-combod-mkxni-mykdsxq-zebmrkcsxq-692[fnhpz]
|
||||||
|
zlkprjbo-doxab-gbiivybxk-xkxivpfp-809[ydtxn]
|
||||||
|
wdjcvuvmyjpn-ezggtwzvi-hvmfzodib-603[vzdgi]
|
||||||
|
njmjubsz-hsbef-fhh-bobmztjt-649[mxkjw]
|
||||||
|
wsvsdkbi-qbkno-oqq-ecob-docdsxq-796[rglok]
|
||||||
|
htsxzrjw-lwfij-gfxpjy-fsfqdxnx-307[uyteb]
|
||||||
|
wpuvcdng-ejqeqncvg-yqtmujqr-882[svamn]
|
||||||
|
tagzsrsjvgmk-hdsklau-yjskk-ugflsafewfl-606[tysrn]
|
||||||
|
kwtwznct-akidmvomz-pcvb-zmamizkp-200[skpom]
|
||||||
|
dpmpsgvm-dboez-dpbujoh-fohjoffsjoh-311[fknst]
|
||||||
|
rnqnyfwd-lwfij-hmthtqfyj-xytwflj-567[gzkol]
|
||||||
|
zntargvp-pnaql-hfre-grfgvat-923[yijbm]
|
||||||
|
dzczkrip-xiruv-treup-tfrkzex-drerxvdvek-347[vrmsu]
|
||||||
|
ajyqqgdgcb-afmamjyrc-sqcp-rcqrgle-522[cqagr]
|
||||||
|
pelbtravp-ohaal-erprvivat-715[jnbmz]
|
||||||
|
irdgrxzex-sleep-ivrthlzjzkzfe-113[bmsnw]
|
||||||
|
eqpuwogt-itcfg-tcddkv-fgxgnqrogpv-804[gtcdf]
|
||||||
|
cvabijtm-moo-ivitgaqa-226[darfu]
|
||||||
|
ytu-xjhwjy-xhfajsljw-mzsy-zxjw-yjxynsl-281[wzjeb]
|
||||||
|
fkqbokxqflkxi-yxphbq-obxznrfpfqflk-809[dcasb]
|
||||||
|
gokzyxsjon-sxdobxkdsyxkv-mkxni-ecob-docdsxq-276[zypso]
|
||||||
|
ibghopzs-suu-kcfygvcd-402[cgsub]
|
||||||
|
tfiifjzmv-srjbvk-uvjzxe-581[sovtj]
|
||||||
|
gntmfefwitzx-gfxpjy-xmnuunsl-619[fnxgm]
|
||||||
|
lgh-kwujwl-bwddqtwsf-vwhsjlewfl-788[tlejf]
|
||||||
|
hjgbwuladw-wyy-ghwjslagfk-164[wgahj]
|
||||||
|
nzwzcqfw-ojp-qtylyntyr-431[ynqtw]
|
||||||
|
sbejpbdujwf-sbccju-vtfs-uftujoh-909[kujit]
|
||||||
|
vhkkhlbox-wrx-ftkdxmbgz-241[uwzex]
|
||||||
|
lahxpnwrl-bljenwpna-qdwc-cajrwrwp-381[yjzno]
|
||||||
|
lugjuacha-jfumncw-alumm-jolwbumcha-838[uamcj]
|
||||||
|
gvcskirmg-glsgspexi-jmrergmrk-828[smeyi]
|
||||||
|
thnulapj-ihzrla-thyrlapun-955[ahlnp]
|
||||||
|
sno-rdbqds-bzmcx-btrsnldq-rdquhbd-937[dbqrs]
|
||||||
|
vdzonmhydc-eknvdq-dmfhmddqhmf-781[dmhfn]
|
||||||
|
iehepwnu-cnwza-xqjju-ykjpwejiajp-368[jepwa]
|
||||||
|
dfcxsqhwzs-dzoghwq-ufogg-cdsfohwcbg-974[gcdfh]
|
||||||
|
sbqiiyvyut-tou-jhqydydw-608[okbzs]
|
||||||
|
htsxzrjw-lwfij-gzssd-uzwhmfxnsl-801[nmtjq]
|
||||||
|
hvbizodx-rzvkjiduzy-xviyt-yzqzgjkhzio-213[zivyd]
|
||||||
|
ajmrxjlcren-ljwmh-lxjcrwp-bqryyrwp-745[kheat]
|
||||||
|
vkppo-shoewudys-tou-udwyduuhydw-556[udowy]
|
||||||
|
dpotvnfs-hsbef-dmbttjgjfe-gmpxfs-nbslfujoh-363[qapli]
|
||||||
|
glrcplyrgmlyj-djmucp-qrmpyec-158[clmpr]
|
||||||
|
emixwvqhml-xtiabqk-oziaa-wxmzibqwva-642[rkpba]
|
||||||
|
qczcftiz-dzoghwq-ufogg-aofyshwbu-298[lmcuy]
|
||||||
|
cvabijtm-zilqwikbqdm-akidmvomz-pcvb-nqvivkqvo-746[ynxzo]
|
||||||
|
pkl-oaynap-acc-wjwhuoeo-134[jxlai]
|
||||||
|
xjmmjndqz-kgvnodx-bmvnn-rjmfncjk-291[njmdk]
|
||||||
|
ejpanjwpekjwh-nwxxep-nayaerejc-550[lisvd]
|
||||||
|
htwwtxnaj-htsxzrjw-lwfij-hfsid-htfynsl-wjfhvznxnynts-541[hntwf]
|
||||||
|
mbiyqoxsm-mkxni-mykdsxq-crszzsxq-770[zhowm]
|
||||||
|
rmn-qcapcr-ucynmlgxcb-cee-pcqcypaf-886[cpaem]
|
||||||
|
rtqlgevkng-ejqeqncvg-fgxgnqrogpv-466[zktns]
|
||||||
|
fydelmwp-mfyyj-nfdezxpc-dpcgtnp-769[anfej]
|
||||||
|
yuxufmdk-sdmpq-otaoaxmfq-pqbxakyqzf-742[ohxti]
|
||||||
|
vxupkizork-igtje-xkgiwaoyozout-592[bmwjf]
|
||||||
|
veqtekmrk-tvsnigxmpi-gerhc-gsexmrk-gywxsqiv-wivzmgi-802[dglps]
|
||||||
|
nsyjwsfyntsfq-uqfxynh-lwfxx-ijuqtdrjsy-931[ymnhu]
|
||||||
|
gifavtkzcv-avccpsvre-fgvirkzfej-841[ypigz]
|
||||||
|
krxqjijamxdb-kdwwh-mnyjacvnwc-641[krnma]
|
||||||
|
dszphfojd-ezf-sftfbsdi-805[fdszb]
|
||||||
|
xmrrq-tmffq-lwuzfgdgyq-372[fqgmr]
|
||||||
|
tagzsrsjvgmk-xdgowj-vwhsjlewfl-788[gjswl]
|
||||||
|
lsyrkjkbnyec-mkxni-nofovyzwoxd-614[knoyx]
|
||||||
|
dwbcjkun-mhn-bjunb-173[mykra]
|
||||||
|
vhehkyne-vtgwr-nlxk-mxlmbgz-319[eghkl]
|
||||||
|
bkzrrhehdc-bnqqnrhud-bzmcx-bnzshmf-otqbgzrhmf-677[xaszn]
|
||||||
|
oxmeeuruqp-bxmefuo-sdmee-abqdmfuaze-248[udtec]
|
||||||
|
jlidywncfy-mwupyhayl-bohn-uhufsmcm-500[yhmuc]
|
||||||
|
xjmmjndqz-zbb-mzvxlpdndodji-239[djmzb]
|
||||||
|
yuxufmdk-sdmpq-omzpk-qzsuzqqduzs-534[ofrpg]
|
||||||
|
tfejldvi-xiruv-vxx-uvgrikdvek-659[cnesm]
|
||||||
|
yaxsnlcrun-ajkkrc-anbnjalq-979[nmivs]
|
||||||
|
tvsnigxmpi-ikk-wivzmgiw-880[agunv]
|
||||||
|
mrxivrexmsrep-tpewxmg-kveww-viwievgl-698[evwim]
|
||||||
|
nglmtuex-yehpxk-labiibgz-241[begil]
|
||||||
|
zuv-ykixkz-ixeumktoi-igtje-iugzotm-aykx-zkyzotm-670[pjybl]
|
||||||
|
forwcoqhwjs-dzoghwq-ufogg-difqvogwbu-272[xkwoz]
|
||||||
|
ajyqqgdgcb-qaytclecp-fslr-bcqgel-886[mkvsi]
|
||||||
|
myxcewob-qbkno-mkxni-mykdsxq-wkbuodsxq-770[zmijb]
|
||||||
|
uwtojhynqj-kqtbjw-yjhmstqtld-333[jtqhw]
|
||||||
|
wsvsdkbi-qbkno-lkcuod-dbksxsxq-406[biaoe]
|
||||||
|
gpbepvxcv-rpcsn-rdpixcv-advxhixrh-895[dcwgp]
|
||||||
|
muqfedyput-isqludwuh-xkdj-mehaixef-712[betdq]
|
||||||
|
ckgvutofkj-inuiurgzk-xkgiwaoyozout-956[sazyo]
|
||||||
|
wfruflnsl-uqfxynh-lwfxx-btwpxmtu-541[fxluw]
|
||||||
|
qfmcusbwq-rms-igsf-hsghwbu-246[sbfgh]
|
||||||
|
ynukcajey-nwxxep-qoan-paopejc-602[htmbv]
|
||||||
|
ujqgywfau-uzgugdslw-jwkwsjuz-138[newms]
|
||||||
|
yflexwxoalrp-zxkav-cfkxkzfkd-705[ctnsy]
|
||||||
|
vjpwncrl-lqxlxujcn-mnyuxhvnwc-953[nawmz]
|
||||||
|
willimcpy-wuhxs-lyuwkocmcncih-786[cilwh]
|
||||||
|
mtzslklcozfd-clmmte-cpnptgtyr-119[tjkgv]
|
||||||
|
xlrypetn-awldetn-rcldd-cplnbftdtetzy-795[tdlen]
|
||||||
|
vkppo-rqiauj-huqsgkyiyjyed-452[yijkp]
|
||||||
|
vxupkizork-lruckx-jkbkruvsktz-124[eumyz]
|
||||||
|
diozmivodjivg-agjrzm-nzmqdxzn-915[otpfl]
|
||||||
|
owshgfarwv-hdsklau-yjskk-klgjsyw-918[qcjim]
|
||||||
|
zuv-ykixkz-igtje-iugzotm-zkinturume-202[plvqf]
|
||||||
|
zlilocri-oxyyfq-bkdfkbbofkd-835[bswmn]
|
||||||
|
ziuxioqvo-lgm-amzdqkma-798[maioq]
|
||||||
|
xqvwdeoh-sodvwlf-judvv-ghyhorsphqw-517[hvdow]
|
||||||
|
ovbunmneqbhf-enqvbnpgvir-onfxrg-qrfvta-507[nvbfq]
|
||||||
|
gbc-frperg-pnaql-genvavat-351[pmzkq]
|
||||||
|
eadalsjq-yjsvw-jsttal-suimakalagf-580[zjghy]
|
||||||
|
rdadguja-rpcsn-rdpixcv-apqdgpidgn-245[dpagr]
|
||||||
|
tbxmlkfwba-pzxsbkdbo-erkq-abpfdk-523[vifrq]
|
||||||
|
ocipgvke-uecxgpigt-jwpv-ugtxkegu-544[abfsh]
|
||||||
|
ovbunmneqbhf-zvyvgnel-tenqr-wryylorna-ybtvfgvpf-481[hxymg]
|
||||||
|
pinovwgz-xjinphzm-bmvyz-agjrzm-ozxcijgjbt-681[cqlnu]
|
||||||
|
tinnm-qobrm-ghcfous-220[hyczt]
|
||||||
|
iuruxlar-yigbktmkx-natz-ykxboiky-748[kixya]
|
||||||
|
bkzrrhehdc-bzmcx-bnzshmf-cdrhfm-209[hbcmr]
|
||||||
|
gpsxdprixkt-tvv-uxcpcrxcv-973[xcpvr]
|
||||||
|
forwcoqhwjs-rms-hfowbwbu-974[stzrm]
|
||||||
|
zovldbkfz-fkqbokxqflkxi-mixpqfz-doxpp-cfkxkzfkd-705[tsmfo]
|
||||||
|
vetllbybxw-lvtoxgzxk-angm-ftgtzxfxgm-371[sbemy]
|
||||||
|
hwbba-ejqeqncvg-tgugctej-232[iyrqv]
|
||||||
|
vqr-ugetgv-lgnnadgcp-wugt-vguvkpi-596[gvunp]
|
||||||
|
xgvnndadzy-wpiit-yzndbi-343[rawyd]
|
||||||
|
jxdkbqfz-oxyyfq-qbzeklildv-107[qbdfk]
|
||||||
|
wlsiayhcw-luvvcn-mufym-656[jbvne]
|
||||||
|
surmhfwloh-fdqgb-ghvljq-621[ymnve]
|
||||||
|
mvkccspson-bkllsd-vklybkdybi-432[yscux]
|
||||||
|
dszphfojd-sbccju-dvtupnfs-tfswjdf-129[itbfs]
|
||||||
|
lsyrkjkbnyec-lexxi-crszzsxq-978[sxcek]
|
||||||
|
qlm-pbzobq-mixpqfz-doxpp-zlkqxfkjbkq-211[satyb]
|
||||||
|
bknsykmdsfo-nio-kmaescsdsyx-744[tspif]
|
||||||
|
bpvctixr-rpcsn-rjhidbtg-htgkxrt-713[rtbcg]
|
||||||
|
sebehvkb-rqiauj-udwyduuhydw-140[udbeh]
|
||||||
|
zhdsrqlchg-fdqgb-hqjlqhhulqj-387[zptrs]
|
||||||
|
qxdwpopgsdjh-rpcsn-sthxvc-635[nbixj]
|
||||||
|
pualyuhapvuhs-msvdly-klzpnu-721[ulpah]
|
||||||
|
sbqiiyvyut-shoewudys-isqludwuh-xkdj-jhqydydw-894[dysuh]
|
||||||
|
wsvsdkbi-qbkno-lexxi-dbksxsxq-614[onzwh]
|
||||||
|
ydjuhdqjyedqb-rqiauj-efuhqjyedi-894[ocdpe]
|
||||||
|
kwzzwaqdm-ntwemz-wxmzibqwva-434[nwzml]
|
||||||
|
qspkfdujmf-fhh-nbobhfnfou-571[zpyau]
|
||||||
|
bxaxipgn-vgpst-tvv-detgpixdch-583[xwiac]
|
||||||
|
qfmcusbwq-dfcxsqhwzs-xszzmpsob-fsqswjwbu-402[lstrx]
|
||||||
|
dpmpsgvm-dboez-sfdfjwjoh-337[dfjmo]
|
||||||
|
dzoghwq-ufogg-fsgsofqv-636[gfoqs]
|
||||||
|
nzwzcqfw-dnlgpyrpc-sfye-qtylyntyr-509[milhd]
|
||||||
|
xgsvgmotm-pkrrehkgt-vaxingyotm-176[jubcm]
|
||||||
|
xgsvgmotm-jek-cuxqynuv-644[soxwn]
|
||||||
|
cxy-bnlanc-lahxpnwrl-kdwwh-fxatbqxy-485[zamhj]
|
||||||
|
irgyyolokj-inuiurgzk-sgtgmksktz-982[vzkrq]
|
||||||
|
xgvnndadzy-xcjxjgvoz-xjiovdihzio-733[ozhyu]
|
||||||
|
gvcskirmg-nippcfier-xiglrspskc-334[bastq]
|
||||||
|
zlilocri-gbiivybxk-obxznrfpfqflk-367[ntyda]
|
||||||
|
pyknyegle-pyzzgr-pcqcypaf-886[nxvzy]
|
||||||
|
zhdsrqlchg-gbh-frqwdlqphqw-361[nqzts]
|
||||||
|
kyelcrga-cee-yaosgqgrgml-808[izdqr]
|
||||||
|
hplazytkpo-prr-cpnptgtyr-379[prtya]
|
598
y2016/resources/6_input.txt
Normal file
598
y2016/resources/6_input.txt
Normal file
@@ -0,0 +1,598 @@
|
|||||||
|
uzmnhwye
|
||||||
|
jvyyfmhr
|
||||||
|
eiwokyzj
|
||||||
|
rghqvfsx
|
||||||
|
pqjbfqey
|
||||||
|
ceqkjgny
|
||||||
|
kbpuzvof
|
||||||
|
epyeucto
|
||||||
|
bqhqvbef
|
||||||
|
tqduwleg
|
||||||
|
ysadziyj
|
||||||
|
onvxrwcl
|
||||||
|
dwbhjkmx
|
||||||
|
qvgqewkr
|
||||||
|
qazepxhd
|
||||||
|
bqtuexvi
|
||||||
|
vieyforp
|
||||||
|
kizhadeh
|
||||||
|
ofpraxry
|
||||||
|
xamrsokr
|
||||||
|
jrrottpf
|
||||||
|
gweaulph
|
||||||
|
gyctgzpo
|
||||||
|
mkddcnuk
|
||||||
|
llbxmhbt
|
||||||
|
mghoubct
|
||||||
|
arhrpksk
|
||||||
|
hzeshlue
|
||||||
|
loygkukn
|
||||||
|
asakqobo
|
||||||
|
vwvjnarb
|
||||||
|
pmqcgzkj
|
||||||
|
soucxjes
|
||||||
|
szsuqdss
|
||||||
|
hyjyxtyi
|
||||||
|
qjsjwjuf
|
||||||
|
cvkuyeit
|
||||||
|
qvlmnzih
|
||||||
|
distpoga
|
||||||
|
dtlpvlub
|
||||||
|
fszspsdu
|
||||||
|
zkpxuozx
|
||||||
|
yumhqgty
|
||||||
|
wetfiqij
|
||||||
|
ozpmcegi
|
||||||
|
ylpbjbru
|
||||||
|
rqksydxz
|
||||||
|
ifayduog
|
||||||
|
xqlhyrhl
|
||||||
|
wrolqshx
|
||||||
|
cliyrafn
|
||||||
|
jtuerdyy
|
||||||
|
damyknzr
|
||||||
|
olbtisgv
|
||||||
|
sdlvkpjg
|
||||||
|
tvfvrshv
|
||||||
|
ugywkitq
|
||||||
|
idjjqpzc
|
||||||
|
eeowwemi
|
||||||
|
npplofdm
|
||||||
|
ouzjrlph
|
||||||
|
foawnibc
|
||||||
|
xcdcepzd
|
||||||
|
irqsuacz
|
||||||
|
xtnmuzqp
|
||||||
|
sgsxsjoj
|
||||||
|
qhkpbuvq
|
||||||
|
tsvwtvtz
|
||||||
|
lgqaycod
|
||||||
|
adttxkwp
|
||||||
|
kjcyqgoc
|
||||||
|
bfkxbgxq
|
||||||
|
iiszhwbf
|
||||||
|
cgnihihb
|
||||||
|
gsgvjypz
|
||||||
|
lgcgjccw
|
||||||
|
rdkltabk
|
||||||
|
wnymgwbv
|
||||||
|
jdfqdvis
|
||||||
|
yxtuyupx
|
||||||
|
nsvafgfo
|
||||||
|
ztmbgjux
|
||||||
|
axugvumx
|
||||||
|
tstqlnye
|
||||||
|
eeyqirow
|
||||||
|
ovaityku
|
||||||
|
cdqyjdkz
|
||||||
|
vuhkumlu
|
||||||
|
rwebkmlj
|
||||||
|
prncgnbt
|
||||||
|
ftuhvnow
|
||||||
|
lhmnkhmy
|
||||||
|
unyaizoz
|
||||||
|
ezshlifw
|
||||||
|
bllzrnar
|
||||||
|
uxblibez
|
||||||
|
fpkclnns
|
||||||
|
zqocayvl
|
||||||
|
umoistgi
|
||||||
|
skmgbxls
|
||||||
|
jgtlmsux
|
||||||
|
nulmpeow
|
||||||
|
rxeyoiwy
|
||||||
|
xpqouwhq
|
||||||
|
ogepecdf
|
||||||
|
paeqseqk
|
||||||
|
auntemaj
|
||||||
|
kyorwfkl
|
||||||
|
tnvbjicg
|
||||||
|
xazuvzok
|
||||||
|
noiksasa
|
||||||
|
tvgkzpcl
|
||||||
|
jqzwlyvl
|
||||||
|
zcbzkese
|
||||||
|
notfmgol
|
||||||
|
vceqbfbg
|
||||||
|
qfeabvhv
|
||||||
|
hejfluqw
|
||||||
|
yoxvxdes
|
||||||
|
pbgiqytr
|
||||||
|
tntrwezn
|
||||||
|
duadnppa
|
||||||
|
nqnwslev
|
||||||
|
okmdpmyr
|
||||||
|
eljfthrk
|
||||||
|
fymbhtes
|
||||||
|
cdyjpcnd
|
||||||
|
qmaihzyz
|
||||||
|
cifmitdm
|
||||||
|
ksjznrxd
|
||||||
|
jdcmoqpo
|
||||||
|
caicyvmw
|
||||||
|
zhgsnmcv
|
||||||
|
idxndssh
|
||||||
|
ppykgzto
|
||||||
|
hvkjejgz
|
||||||
|
dezkqhas
|
||||||
|
ddfpqxfu
|
||||||
|
zabdhasf
|
||||||
|
qkhgknfl
|
||||||
|
gqrzmfdv
|
||||||
|
lnzrgbwm
|
||||||
|
wrytspbl
|
||||||
|
bsjzukak
|
||||||
|
kfpcoyua
|
||||||
|
zzbpiifh
|
||||||
|
ygrhxtug
|
||||||
|
zedbugkr
|
||||||
|
sienwiyq
|
||||||
|
vpophmnv
|
||||||
|
kvrgegtp
|
||||||
|
azpkkojs
|
||||||
|
jgwlwtjo
|
||||||
|
azwbmxgy
|
||||||
|
wblpgwvu
|
||||||
|
jwkustki
|
||||||
|
fmjixbct
|
||||||
|
ghkclypp
|
||||||
|
erczaojx
|
||||||
|
iqmhmlkf
|
||||||
|
yfqnajza
|
||||||
|
vhpadprc
|
||||||
|
hjicylfh
|
||||||
|
mwbavklg
|
||||||
|
txhtbhbm
|
||||||
|
pufqjjei
|
||||||
|
zazwoxia
|
||||||
|
yhzexooi
|
||||||
|
vuqtvkuv
|
||||||
|
mppianmz
|
||||||
|
tscbvqrg
|
||||||
|
hajzaamg
|
||||||
|
urqizitm
|
||||||
|
ircgrvlo
|
||||||
|
jgzcpbjo
|
||||||
|
erpiqxlw
|
||||||
|
xvnqbjqc
|
||||||
|
xauztetw
|
||||||
|
bcytezdp
|
||||||
|
sqwrbgjb
|
||||||
|
tinldoyz
|
||||||
|
rdkbfbew
|
||||||
|
kkpmcqid
|
||||||
|
fjiztfcy
|
||||||
|
ybdoeafy
|
||||||
|
burdrehw
|
||||||
|
uyredvvm
|
||||||
|
bwvobekv
|
||||||
|
fniozvjr
|
||||||
|
ifaoxink
|
||||||
|
zaoujdun
|
||||||
|
bykdovxw
|
||||||
|
wasdjrzy
|
||||||
|
uxokzwlb
|
||||||
|
votizlio
|
||||||
|
leoxtnlc
|
||||||
|
ymcesetp
|
||||||
|
mibahaht
|
||||||
|
ldgfbbar
|
||||||
|
aaegvpyn
|
||||||
|
etgdecrd
|
||||||
|
cbqerkil
|
||||||
|
myldihga
|
||||||
|
aycsmksz
|
||||||
|
sbdprnva
|
||||||
|
ytlllxsq
|
||||||
|
shxuxktj
|
||||||
|
otxymese
|
||||||
|
hygjpofa
|
||||||
|
lozdcvfn
|
||||||
|
ulrvezsj
|
||||||
|
elflfepx
|
||||||
|
xtyqbbaz
|
||||||
|
wombapna
|
||||||
|
uesqfrfo
|
||||||
|
amagopph
|
||||||
|
tdipmqwo
|
||||||
|
qlfhnwxp
|
||||||
|
qycwncct
|
||||||
|
haofnvsq
|
||||||
|
bwiyooof
|
||||||
|
fdftgidb
|
||||||
|
xzntthfa
|
||||||
|
ouzddcqt
|
||||||
|
fywssrae
|
||||||
|
ywmmvhut
|
||||||
|
gphtugjk
|
||||||
|
qxfymjuh
|
||||||
|
dbnxhxac
|
||||||
|
mvwunqfa
|
||||||
|
tfrrjcnr
|
||||||
|
lycvubak
|
||||||
|
pfxofasn
|
||||||
|
xiacctnn
|
||||||
|
vrlncgrn
|
||||||
|
wjkeqsav
|
||||||
|
vskxlpkf
|
||||||
|
iaknsppj
|
||||||
|
kzexhdzd
|
||||||
|
jesglqmn
|
||||||
|
lkqtzgzd
|
||||||
|
wnwksqbf
|
||||||
|
htqrcgyq
|
||||||
|
jjynwudx
|
||||||
|
lawnwevw
|
||||||
|
cfewlcwu
|
||||||
|
ledcrfvq
|
||||||
|
zlfpilwv
|
||||||
|
jckvhaly
|
||||||
|
xhggozqd
|
||||||
|
hrnuxzwq
|
||||||
|
ajominjf
|
||||||
|
bkoaxnil
|
||||||
|
zcjslwqq
|
||||||
|
vgexcqtl
|
||||||
|
ddfannml
|
||||||
|
ufbfceuh
|
||||||
|
vuibklnx
|
||||||
|
tmrtgqxx
|
||||||
|
izxwfael
|
||||||
|
njtzahxu
|
||||||
|
bzwyyycr
|
||||||
|
ggxoqbvo
|
||||||
|
oysvzvoi
|
||||||
|
ejxxjhjl
|
||||||
|
unwkfzyr
|
||||||
|
nwycafcu
|
||||||
|
lfqieudu
|
||||||
|
natvibge
|
||||||
|
qzrnpxew
|
||||||
|
mqjbtpmh
|
||||||
|
ixdsjywf
|
||||||
|
nmilafsn
|
||||||
|
tfwubeot
|
||||||
|
ccmrtlfs
|
||||||
|
uajfiusi
|
||||||
|
jhinkyxm
|
||||||
|
qwcvvimb
|
||||||
|
wlbhjanf
|
||||||
|
vdcedtkw
|
||||||
|
uiibfsbh
|
||||||
|
hkgxmybs
|
||||||
|
lsqlrxll
|
||||||
|
ihvodcrb
|
||||||
|
ewrfalkm
|
||||||
|
kelnqkcd
|
||||||
|
vroxnjwh
|
||||||
|
jeneowpg
|
||||||
|
ozivuper
|
||||||
|
fxatuncj
|
||||||
|
dchmobvr
|
||||||
|
oyxqiszo
|
||||||
|
uuyxgshp
|
||||||
|
sxcbjmhu
|
||||||
|
dorsqxgt
|
||||||
|
urygoghb
|
||||||
|
lolotlqh
|
||||||
|
ytaalnkv
|
||||||
|
bcspchnq
|
||||||
|
wbdululm
|
||||||
|
vzqwkjix
|
||||||
|
hinyyoag
|
||||||
|
qkyqkdit
|
||||||
|
lolhbfkp
|
||||||
|
zlwjxdoa
|
||||||
|
yudtkctc
|
||||||
|
xcvazkiu
|
||||||
|
ttvfuzxr
|
||||||
|
rqfrdkcm
|
||||||
|
rihwltdh
|
||||||
|
qcpjwsjz
|
||||||
|
bazpmmmx
|
||||||
|
grxiwhag
|
||||||
|
cbljykhx
|
||||||
|
weooldcv
|
||||||
|
lumfsfwj
|
||||||
|
kiunrfgy
|
||||||
|
fafbvyjx
|
||||||
|
acpzgmgh
|
||||||
|
pdyhmtvq
|
||||||
|
ssismufm
|
||||||
|
pdlzydrn
|
||||||
|
sxxbtkqi
|
||||||
|
gnuxwgui
|
||||||
|
wcuguqju
|
||||||
|
jkjkdkph
|
||||||
|
prpmfknq
|
||||||
|
csuabssx
|
||||||
|
khymlrkm
|
||||||
|
muavohgo
|
||||||
|
sqgzadar
|
||||||
|
svzwomsw
|
||||||
|
zfscsyyh
|
||||||
|
rhuwuqij
|
||||||
|
otxcyjya
|
||||||
|
ftecgqvj
|
||||||
|
nbdrbipz
|
||||||
|
sppapkeb
|
||||||
|
xxysrbxg
|
||||||
|
pkvvzfwx
|
||||||
|
mpadytha
|
||||||
|
iqbdgpwm
|
||||||
|
aqisvbnk
|
||||||
|
ipckdhwl
|
||||||
|
rkivzxzk
|
||||||
|
tkiykice
|
||||||
|
jmpfxvqq
|
||||||
|
shrwhvwl
|
||||||
|
uxlgxmgf
|
||||||
|
nhjjylml
|
||||||
|
ujvjqgao
|
||||||
|
yekgzrqv
|
||||||
|
ujbnxfya
|
||||||
|
pmtovthi
|
||||||
|
hsazctam
|
||||||
|
hhmesojw
|
||||||
|
vgxomjtg
|
||||||
|
ucudhxze
|
||||||
|
kzgkdvlj
|
||||||
|
vtjkjgrj
|
||||||
|
fticzjct
|
||||||
|
dwulyubi
|
||||||
|
fyfiwbkt
|
||||||
|
orcuggcq
|
||||||
|
kvxqcwfz
|
||||||
|
vvjeoumv
|
||||||
|
xsyobzop
|
||||||
|
iszghxbl
|
||||||
|
kxxvtiuf
|
||||||
|
klwsferz
|
||||||
|
emzmpfvt
|
||||||
|
gnsxgbib
|
||||||
|
nnrmtcdj
|
||||||
|
qqnfngkm
|
||||||
|
lkdxvyxe
|
||||||
|
vkeaswre
|
||||||
|
kfvpnnpd
|
||||||
|
mozumbpg
|
||||||
|
omwjojxc
|
||||||
|
sjmkijsk
|
||||||
|
fivvusjy
|
||||||
|
esmktnbm
|
||||||
|
mbkizlzq
|
||||||
|
mscagsvf
|
||||||
|
twpwpsbj
|
||||||
|
okwrcirc
|
||||||
|
hcexoyjh
|
||||||
|
tzhxxmkr
|
||||||
|
zfhzgnoe
|
||||||
|
soldpmdf
|
||||||
|
ejikyuba
|
||||||
|
cudjzzmg
|
||||||
|
xfwpcilo
|
||||||
|
vpjqpuyk
|
||||||
|
oprtpooj
|
||||||
|
djzadomw
|
||||||
|
shuqtulp
|
||||||
|
rlspstxi
|
||||||
|
gxbfmsqv
|
||||||
|
qoojsatd
|
||||||
|
rvupwphy
|
||||||
|
zfgqbrwb
|
||||||
|
ninnufxt
|
||||||
|
annvdtct
|
||||||
|
phwyfyjt
|
||||||
|
qxwfsujq
|
||||||
|
bwrbuwxs
|
||||||
|
ihwlqjbr
|
||||||
|
zylvjunv
|
||||||
|
bmmsjzxk
|
||||||
|
rvfidswe
|
||||||
|
fjgovnmk
|
||||||
|
mogllpfx
|
||||||
|
ddsefzqd
|
||||||
|
wrssovrq
|
||||||
|
yaqhesmy
|
||||||
|
cvvcswup
|
||||||
|
kpmipygw
|
||||||
|
xrjtbhze
|
||||||
|
nqucxgea
|
||||||
|
kpbbhdhz
|
||||||
|
fhdsgcdm
|
||||||
|
pmjidvmk
|
||||||
|
szbhczpa
|
||||||
|
tchjtqzu
|
||||||
|
qzorzcpu
|
||||||
|
mfnvijyy
|
||||||
|
wuutyddc
|
||||||
|
ysupoemc
|
||||||
|
dunwqmbn
|
||||||
|
mocewxzi
|
||||||
|
qiwracmo
|
||||||
|
rmbbhvud
|
||||||
|
cltnmdiy
|
||||||
|
ruutdaeo
|
||||||
|
wihpnryn
|
||||||
|
mgajpkys
|
||||||
|
iahfwmuw
|
||||||
|
vuocxwiu
|
||||||
|
mbygminp
|
||||||
|
kmkjaead
|
||||||
|
hxnztxbh
|
||||||
|
flnxmtbj
|
||||||
|
nkbrfcqg
|
||||||
|
blkvlojl
|
||||||
|
ppdielzk
|
||||||
|
ssclzhip
|
||||||
|
qvvymayo
|
||||||
|
cthwrgfx
|
||||||
|
rjqdlnep
|
||||||
|
hccjexgw
|
||||||
|
cbclqcga
|
||||||
|
cxjjdgvu
|
||||||
|
puthjawq
|
||||||
|
gvvzvjac
|
||||||
|
wtxxtwef
|
||||||
|
retdqdpn
|
||||||
|
hifhvrbd
|
||||||
|
jctkaclz
|
||||||
|
bftzisge
|
||||||
|
wofmrtss
|
||||||
|
fvojyyar
|
||||||
|
cbnhtlqp
|
||||||
|
jqozxhny
|
||||||
|
ybgsemfv
|
||||||
|
ooaqxove
|
||||||
|
gqvrbkqy
|
||||||
|
ppdcrmte
|
||||||
|
clfxucnu
|
||||||
|
toenbwtd
|
||||||
|
jzmywsup
|
||||||
|
inqsaqid
|
||||||
|
aehpaztz
|
||||||
|
gragbfrw
|
||||||
|
dlrjyzmu
|
||||||
|
sblqqwsb
|
||||||
|
gzruigwt
|
||||||
|
aplpzlui
|
||||||
|
wmrpyrjm
|
||||||
|
xyxwaeog
|
||||||
|
bhkpwzvo
|
||||||
|
egdpnujd
|
||||||
|
hbbdjlws
|
||||||
|
mbphcthb
|
||||||
|
bykhifcd
|
||||||
|
rrwkidpm
|
||||||
|
iztrhfnf
|
||||||
|
nydlpqze
|
||||||
|
dgulsfzt
|
||||||
|
eludirwj
|
||||||
|
iyvbrttp
|
||||||
|
aerocrzf
|
||||||
|
ejaearsc
|
||||||
|
dxruknqe
|
||||||
|
zmhbnkls
|
||||||
|
qnsykqvu
|
||||||
|
gotmslog
|
||||||
|
nbprjbxc
|
||||||
|
gtlykrzb
|
||||||
|
egethaib
|
||||||
|
flomperi
|
||||||
|
xcamglue
|
||||||
|
zceleqek
|
||||||
|
cnvgfdwf
|
||||||
|
dchfyogi
|
||||||
|
ygtzquvk
|
||||||
|
xxxunqji
|
||||||
|
amqehkhx
|
||||||
|
lsacrdtm
|
||||||
|
ybnapfyu
|
||||||
|
aiukmmqc
|
||||||
|
pepgjpqa
|
||||||
|
uermcxac
|
||||||
|
kapeodph
|
||||||
|
ozdanagr
|
||||||
|
pdjfzxdb
|
||||||
|
ioospvis
|
||||||
|
uhxuoyrd
|
||||||
|
jnnlwvdv
|
||||||
|
gnxaqkly
|
||||||
|
zsiucnpt
|
||||||
|
gtveajfy
|
||||||
|
tudfnxqg
|
||||||
|
pwugrcdu
|
||||||
|
obeeyadl
|
||||||
|
yhybzygs
|
||||||
|
enbwkfwn
|
||||||
|
iiziwmrj
|
||||||
|
rmldlsrp
|
||||||
|
wfqifmcn
|
||||||
|
aehofonk
|
||||||
|
bvxavoez
|
||||||
|
fwelvohr
|
||||||
|
eviaivqh
|
||||||
|
yjwslphn
|
||||||
|
wjdocdoc
|
||||||
|
dqgiuhli
|
||||||
|
geinepsk
|
||||||
|
npaemvap
|
||||||
|
ngnqfbvw
|
||||||
|
pobgwlhb
|
||||||
|
zufxdrkb
|
||||||
|
ggfdeuts
|
||||||
|
defhitoc
|
||||||
|
ndzvtils
|
||||||
|
oysmqhnq
|
||||||
|
tdmsbwqi
|
||||||
|
wwfvshad
|
||||||
|
btkerpuz
|
||||||
|
gwqvhvto
|
||||||
|
nflozwyk
|
||||||
|
tbiexdrg
|
||||||
|
okshetxm
|
||||||
|
mbgrhojh
|
||||||
|
eluzaxsb
|
||||||
|
hwqtiqwr
|
||||||
|
yrsddclj
|
||||||
|
wrsfnbdb
|
||||||
|
klfmnoqq
|
||||||
|
ztmkgmgg
|
||||||
|
xnkrekxs
|
||||||
|
qmdwfeuo
|
||||||
|
jwzfwhkv
|
||||||
|
nxjlnbiy
|
||||||
|
vdhnrrxi
|
||||||
|
smgjcxcp
|
||||||
|
aphleuvc
|
||||||
|
ljbadhdn
|
||||||
|
jkbnkinm
|
||||||
|
mjtovsxa
|
||||||
|
xpjsorxu
|
||||||
|
gicuerdc
|
||||||
|
azrhkarl
|
||||||
|
hpgwlzge
|
||||||
|
bweruitv
|
||||||
|
vnoglwep
|
||||||
|
pjwqtqdb
|
||||||
|
myvyrjye
|
||||||
|
xiqzlwfn
|
||||||
|
zqpnhjnn
|
||||||
|
hkzycpkb
|
||||||
|
fmoryqng
|
||||||
|
dfembrgo
|
||||||
|
dvguwian
|
||||||
|
rwgwffsn
|
||||||
|
ixgfpslt
|
||||||
|
rkxnxyff
|
||||||
|
ljankcms
|
||||||
|
kksozyit
|
||||||
|
cncygufc
|
||||||
|
agsevmlz
|
||||||
|
ectijrxs
|
||||||
|
rhvtaplx
|
||||||
|
hxddxhda
|
||||||
|
mpvfoaim
|
||||||
|
rtxkcevq
|
||||||
|
qythgaev
|
||||||
|
lnhqdrzc
|
2000
y2016/resources/7_input.txt
Normal file
2000
y2016/resources/7_input.txt
Normal file
File diff suppressed because it is too large
Load Diff
162
y2016/resources/8_input.txt
Normal file
162
y2016/resources/8_input.txt
Normal file
@@ -0,0 +1,162 @@
|
|||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 6
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 3
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 5
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 4
|
||||||
|
rect 2x1
|
||||||
|
rotate row y=0 by 5
|
||||||
|
rect 2x1
|
||||||
|
rotate row y=0 by 2
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 5
|
||||||
|
rect 4x1
|
||||||
|
rotate row y=0 by 2
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 3
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 3
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 2
|
||||||
|
rect 1x1
|
||||||
|
rotate row y=0 by 6
|
||||||
|
rect 4x1
|
||||||
|
rotate row y=0 by 4
|
||||||
|
rotate column x=0 by 1
|
||||||
|
rect 3x1
|
||||||
|
rotate row y=0 by 6
|
||||||
|
rotate column x=0 by 1
|
||||||
|
rect 4x1
|
||||||
|
rotate column x=10 by 1
|
||||||
|
rotate row y=2 by 16
|
||||||
|
rotate row y=0 by 8
|
||||||
|
rotate column x=5 by 1
|
||||||
|
rotate column x=0 by 1
|
||||||
|
rect 7x1
|
||||||
|
rotate column x=37 by 1
|
||||||
|
rotate column x=21 by 2
|
||||||
|
rotate column x=15 by 1
|
||||||
|
rotate column x=11 by 2
|
||||||
|
rotate row y=2 by 39
|
||||||
|
rotate row y=0 by 36
|
||||||
|
rotate column x=33 by 2
|
||||||
|
rotate column x=32 by 1
|
||||||
|
rotate column x=28 by 2
|
||||||
|
rotate column x=27 by 1
|
||||||
|
rotate column x=25 by 1
|
||||||
|
rotate column x=22 by 1
|
||||||
|
rotate column x=21 by 2
|
||||||
|
rotate column x=20 by 3
|
||||||
|
rotate column x=18 by 1
|
||||||
|
rotate column x=15 by 2
|
||||||
|
rotate column x=12 by 1
|
||||||
|
rotate column x=10 by 1
|
||||||
|
rotate column x=6 by 2
|
||||||
|
rotate column x=5 by 1
|
||||||
|
rotate column x=2 by 1
|
||||||
|
rotate column x=0 by 1
|
||||||
|
rect 35x1
|
||||||
|
rotate column x=45 by 1
|
||||||
|
rotate row y=1 by 28
|
||||||
|
rotate column x=38 by 2
|
||||||
|
rotate column x=33 by 1
|
||||||
|
rotate column x=28 by 1
|
||||||
|
rotate column x=23 by 1
|
||||||
|
rotate column x=18 by 1
|
||||||
|
rotate column x=13 by 2
|
||||||
|
rotate column x=8 by 1
|
||||||
|
rotate column x=3 by 1
|
||||||
|
rotate row y=3 by 2
|
||||||
|
rotate row y=2 by 2
|
||||||
|
rotate row y=1 by 5
|
||||||
|
rotate row y=0 by 1
|
||||||
|
rect 1x5
|
||||||
|
rotate column x=43 by 1
|
||||||
|
rotate column x=31 by 1
|
||||||
|
rotate row y=4 by 35
|
||||||
|
rotate row y=3 by 20
|
||||||
|
rotate row y=1 by 27
|
||||||
|
rotate row y=0 by 20
|
||||||
|
rotate column x=17 by 1
|
||||||
|
rotate column x=15 by 1
|
||||||
|
rotate column x=12 by 1
|
||||||
|
rotate column x=11 by 2
|
||||||
|
rotate column x=10 by 1
|
||||||
|
rotate column x=8 by 1
|
||||||
|
rotate column x=7 by 1
|
||||||
|
rotate column x=5 by 1
|
||||||
|
rotate column x=3 by 2
|
||||||
|
rotate column x=2 by 1
|
||||||
|
rotate column x=0 by 1
|
||||||
|
rect 19x1
|
||||||
|
rotate column x=20 by 3
|
||||||
|
rotate column x=14 by 1
|
||||||
|
rotate column x=9 by 1
|
||||||
|
rotate row y=4 by 15
|
||||||
|
rotate row y=3 by 13
|
||||||
|
rotate row y=2 by 15
|
||||||
|
rotate row y=1 by 18
|
||||||
|
rotate row y=0 by 15
|
||||||
|
rotate column x=13 by 1
|
||||||
|
rotate column x=12 by 1
|
||||||
|
rotate column x=11 by 3
|
||||||
|
rotate column x=10 by 1
|
||||||
|
rotate column x=8 by 1
|
||||||
|
rotate column x=7 by 1
|
||||||
|
rotate column x=6 by 1
|
||||||
|
rotate column x=5 by 1
|
||||||
|
rotate column x=3 by 2
|
||||||
|
rotate column x=2 by 1
|
||||||
|
rotate column x=1 by 1
|
||||||
|
rotate column x=0 by 1
|
||||||
|
rect 14x1
|
||||||
|
rotate row y=3 by 47
|
||||||
|
rotate column x=19 by 3
|
||||||
|
rotate column x=9 by 3
|
||||||
|
rotate column x=4 by 3
|
||||||
|
rotate row y=5 by 5
|
||||||
|
rotate row y=4 by 5
|
||||||
|
rotate row y=3 by 8
|
||||||
|
rotate row y=1 by 5
|
||||||
|
rotate column x=3 by 2
|
||||||
|
rotate column x=2 by 3
|
||||||
|
rotate column x=1 by 2
|
||||||
|
rotate column x=0 by 2
|
||||||
|
rect 4x2
|
||||||
|
rotate column x=35 by 5
|
||||||
|
rotate column x=20 by 3
|
||||||
|
rotate column x=10 by 5
|
||||||
|
rotate column x=3 by 2
|
||||||
|
rotate row y=5 by 20
|
||||||
|
rotate row y=3 by 30
|
||||||
|
rotate row y=2 by 45
|
||||||
|
rotate row y=1 by 30
|
||||||
|
rotate column x=48 by 5
|
||||||
|
rotate column x=47 by 5
|
||||||
|
rotate column x=46 by 3
|
||||||
|
rotate column x=45 by 4
|
||||||
|
rotate column x=43 by 5
|
||||||
|
rotate column x=42 by 5
|
||||||
|
rotate column x=41 by 5
|
||||||
|
rotate column x=38 by 1
|
||||||
|
rotate column x=37 by 5
|
||||||
|
rotate column x=36 by 5
|
||||||
|
rotate column x=35 by 1
|
||||||
|
rotate column x=33 by 1
|
||||||
|
rotate column x=32 by 5
|
||||||
|
rotate column x=31 by 5
|
||||||
|
rotate column x=28 by 5
|
||||||
|
rotate column x=27 by 5
|
||||||
|
rotate column x=26 by 5
|
||||||
|
rotate column x=17 by 5
|
||||||
|
rotate column x=16 by 5
|
||||||
|
rotate column x=15 by 4
|
||||||
|
rotate column x=13 by 1
|
||||||
|
rotate column x=12 by 5
|
||||||
|
rotate column x=11 by 5
|
||||||
|
rotate column x=10 by 1
|
||||||
|
rotate column x=8 by 1
|
||||||
|
rotate column x=2 by 5
|
||||||
|
rotate column x=1 by 5
|
27
y2016/src/bin/d1.rs
Normal file
27
y2016/src/bin/d1.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d1;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/1_input.txt")).unwrap();
|
||||||
|
println!("{}", d1::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/1_input.txt")).unwrap();
|
||||||
|
println!("{}", d1::process_part2(&content));
|
||||||
|
}
|
27
y2016/src/bin/d2.rs
Normal file
27
y2016/src/bin/d2.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d2;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/2_input.txt")).unwrap();
|
||||||
|
println!("{}", d2::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/2_input.txt")).unwrap();
|
||||||
|
println!("{}", d2::process_part2(&content));
|
||||||
|
}
|
27
y2016/src/bin/d3.rs
Normal file
27
y2016/src/bin/d3.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d3;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/3_input.txt")).unwrap();
|
||||||
|
println!("{}", d3::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/3_input.txt")).unwrap();
|
||||||
|
println!("{}", d3::process_part2(&content));
|
||||||
|
}
|
27
y2016/src/bin/d4.rs
Normal file
27
y2016/src/bin/d4.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d4;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/4_input.txt")).unwrap();
|
||||||
|
println!("{}", d4::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/4_input.txt")).unwrap();
|
||||||
|
println!("{}", d4::process_part2(&content));
|
||||||
|
}
|
23
y2016/src/bin/d5.rs
Normal file
23
y2016/src/bin/d5.rs
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
use std::time::Instant;
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d5;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
println!("{}", d5::process_part1("ojvtpuvg"));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
println!("{}", d5::process_part2("ojvtpuvg"));
|
||||||
|
}
|
27
y2016/src/bin/d6.rs
Normal file
27
y2016/src/bin/d6.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d6;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/6_input.txt")).unwrap();
|
||||||
|
println!("{}", d6::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/6_input.txt")).unwrap();
|
||||||
|
println!("{}", d6::process_part2(&content));
|
||||||
|
}
|
27
y2016/src/bin/d7.rs
Normal file
27
y2016/src/bin/d7.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d7;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/7_input.txt")).unwrap();
|
||||||
|
println!("{}", d7::process_part1(&content));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/7_input.txt")).unwrap();
|
||||||
|
println!("{}", d7::process_part2(&content));
|
||||||
|
}
|
27
y2016/src/bin/d8.rs
Normal file
27
y2016/src/bin/d8.rs
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
use std::{fs, time::Instant};
|
||||||
|
|
||||||
|
use utils::time::get_elapsed_string;
|
||||||
|
use y2016::days::d8;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 1:");
|
||||||
|
part1();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
let now = Instant::now();
|
||||||
|
println!("Part 2:");
|
||||||
|
part2();
|
||||||
|
println!("Ran in {}", get_elapsed_string(now.elapsed()));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/8_input.txt")).unwrap();
|
||||||
|
println!("{}", d8::process_part1(&content, (50, 6)));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2() {
|
||||||
|
let root = env!("CARGO_MANIFEST_DIR");
|
||||||
|
let content = fs::read_to_string(format!("{root}/resources/8_input.txt")).unwrap();
|
||||||
|
println!("{}", d8::process_part2(&content));
|
||||||
|
}
|
105
y2016/src/days/d1.rs
Normal file
105
y2016/src/days/d1.rs
Normal file
@@ -0,0 +1,105 @@
|
|||||||
|
use core::panic;
|
||||||
|
use std::collections::{HashMap, HashSet};
|
||||||
|
|
||||||
|
#[derive(Clone, Copy, Hash, PartialEq, Eq)]
|
||||||
|
enum Orientation {
|
||||||
|
North,
|
||||||
|
East,
|
||||||
|
South,
|
||||||
|
West,
|
||||||
|
}
|
||||||
|
|
||||||
|
impl Orientation {
|
||||||
|
fn turn(&mut self, direction: &str) {
|
||||||
|
match direction {
|
||||||
|
"R" => match self {
|
||||||
|
Orientation::North => *self = Self::East,
|
||||||
|
Orientation::East => *self = Self::South,
|
||||||
|
Orientation::South => *self = Self::West,
|
||||||
|
Orientation::West => *self = Self::North,
|
||||||
|
},
|
||||||
|
"L" => match self {
|
||||||
|
Orientation::North => *self = Self::West,
|
||||||
|
Orientation::West => *self = Self::South,
|
||||||
|
Orientation::South => *self = Self::East,
|
||||||
|
Orientation::East => *self = Self::North,
|
||||||
|
},
|
||||||
|
_ => panic!("Wrong direction. Only R and L allowed"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> i32 {
|
||||||
|
let mut orientation = Orientation::North;
|
||||||
|
let mut movements = HashMap::new();
|
||||||
|
let mut input = input.to_string();
|
||||||
|
input.pop();
|
||||||
|
for movement in input.split(", ") {
|
||||||
|
let (direction, blocks) = movement.split_at(1);
|
||||||
|
orientation.turn(direction);
|
||||||
|
let blocks = blocks.parse::<i32>().unwrap();
|
||||||
|
movements
|
||||||
|
.entry(orientation)
|
||||||
|
.and_modify(|distance| *distance += blocks)
|
||||||
|
.or_insert(blocks);
|
||||||
|
}
|
||||||
|
let up = movements.get(&Orientation::North).unwrap_or(&0);
|
||||||
|
let down = movements.get(&Orientation::South).unwrap_or(&0);
|
||||||
|
let left = movements.get(&Orientation::West).unwrap_or(&0);
|
||||||
|
let right = movements.get(&Orientation::East).unwrap_or(&0);
|
||||||
|
(up - down).abs() + (left - right).abs()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> i32 {
|
||||||
|
let mut orientation = Orientation::North;
|
||||||
|
let mut visited_coords = HashSet::new();
|
||||||
|
let mut horizontal: i32 = 0;
|
||||||
|
let mut vertical: i32 = 0;
|
||||||
|
let mut input = input.to_string();
|
||||||
|
input.pop();
|
||||||
|
for movement in input.split(", ") {
|
||||||
|
let (direction, blocks) = movement.split_at(1);
|
||||||
|
orientation.turn(direction);
|
||||||
|
let blocks = blocks.parse::<i32>().unwrap();
|
||||||
|
for _block in 1..=blocks {
|
||||||
|
match orientation {
|
||||||
|
Orientation::North => vertical += 1,
|
||||||
|
Orientation::South => vertical -= 1,
|
||||||
|
Orientation::East => horizontal += 1,
|
||||||
|
Orientation::West => horizontal -= 1,
|
||||||
|
}
|
||||||
|
if visited_coords.contains(&(horizontal, vertical)) {
|
||||||
|
return horizontal.abs() + vertical.abs();
|
||||||
|
} else {
|
||||||
|
visited_coords.insert((horizontal, vertical));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
panic!("Did not find easter bunny hq");
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT1: &str = "R2, L3 ";
|
||||||
|
const INPUT2: &str = "R2, R2, R2 ";
|
||||||
|
const INPUT3: &str = "R5, L5, R5, R3 ";
|
||||||
|
const INPUT4: &str = "R8, R4, R4, R8 ";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT1);
|
||||||
|
assert_eq!(result, 5);
|
||||||
|
let result = process_part1(INPUT2);
|
||||||
|
assert_eq!(result, 2);
|
||||||
|
let result = process_part1(INPUT3);
|
||||||
|
assert_eq!(result, 12);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT4);
|
||||||
|
assert_eq!(result, 4);
|
||||||
|
}
|
||||||
|
}
|
133
y2016/src/days/d2.rs
Normal file
133
y2016/src/days/d2.rs
Normal file
@@ -0,0 +1,133 @@
|
|||||||
|
use core::panic;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> String {
|
||||||
|
let mut position = (0, 0);
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.map(|line| {
|
||||||
|
for char in line.chars() {
|
||||||
|
match char {
|
||||||
|
'U' => {
|
||||||
|
if position.1 != -1 {
|
||||||
|
position.1 -= 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'D' => {
|
||||||
|
if position.1 != 1 {
|
||||||
|
position.1 += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'L' => {
|
||||||
|
if position.0 != -1 {
|
||||||
|
position.0 -= 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'R' => {
|
||||||
|
if position.0 != 1 {
|
||||||
|
position.0 += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_ => panic!("Unknown direction {char}"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
key_from_position(position)
|
||||||
|
})
|
||||||
|
.collect::<Vec<String>>()
|
||||||
|
.join("")
|
||||||
|
}
|
||||||
|
|
||||||
|
fn key_from_position(position: (i32, i32)) -> String {
|
||||||
|
match position {
|
||||||
|
(-1, -1) => "1",
|
||||||
|
(0, -1) => "2",
|
||||||
|
(1, -1) => "3",
|
||||||
|
(-1, 0) => "4",
|
||||||
|
(0, 0) => "5",
|
||||||
|
(1, 0) => "6",
|
||||||
|
(-1, 1) => "7",
|
||||||
|
(0, 1) => "8",
|
||||||
|
(1, 1) => "9",
|
||||||
|
(_, _) => panic!("No key at position {}, {}", position.0, position.1),
|
||||||
|
}
|
||||||
|
.to_string()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> String {
|
||||||
|
let mut position: (i32, i32) = (-2, 0);
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.map(|line| {
|
||||||
|
for char in line.chars() {
|
||||||
|
let v_bound = 2 - position.0.abs();
|
||||||
|
let h_bound = 2 - position.1.abs();
|
||||||
|
match char {
|
||||||
|
'U' => {
|
||||||
|
if position.1 > -v_bound {
|
||||||
|
position.1 -= 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'D' => {
|
||||||
|
if position.1 < v_bound {
|
||||||
|
position.1 += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'L' => {
|
||||||
|
if position.0 > -h_bound {
|
||||||
|
position.0 -= 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
'R' => {
|
||||||
|
if position.0 < h_bound {
|
||||||
|
position.0 += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
_ => panic!("Unknown direction {char}"),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
key_from_position_p2(position)
|
||||||
|
})
|
||||||
|
.collect::<Vec<String>>()
|
||||||
|
.join("")
|
||||||
|
}
|
||||||
|
|
||||||
|
fn key_from_position_p2(position: (i32, i32)) -> String {
|
||||||
|
match position {
|
||||||
|
(0, -2) => "1",
|
||||||
|
(-1, -1) => "2",
|
||||||
|
(0, -1) => "3",
|
||||||
|
(1, -1) => "4",
|
||||||
|
(-2, 0) => "5",
|
||||||
|
(-1, 0) => "6",
|
||||||
|
(0, 0) => "7",
|
||||||
|
(1, 0) => "8",
|
||||||
|
(2, 0) => "9",
|
||||||
|
(-1, 1) => "A",
|
||||||
|
(0, 1) => "B",
|
||||||
|
(1, 1) => "C",
|
||||||
|
(0, 2) => "D",
|
||||||
|
(_, _) => panic!("No key at position {}, {}", position.0, position.1),
|
||||||
|
}
|
||||||
|
.to_string()
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "ULL
|
||||||
|
RRDDD
|
||||||
|
LURDL
|
||||||
|
UUUUD";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, "1985".to_string());
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, "5DB3".to_string());
|
||||||
|
}
|
||||||
|
}
|
60
y2016/src/days/d3.rs
Normal file
60
y2016/src/days/d3.rs
Normal file
@@ -0,0 +1,60 @@
|
|||||||
|
pub fn process_part1(input: &str) -> i32 {
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.map(|line| {
|
||||||
|
let sides = line
|
||||||
|
.split_whitespace()
|
||||||
|
.map(|side| side.parse::<u32>().unwrap())
|
||||||
|
.collect::<Vec<u32>>();
|
||||||
|
if sides[0] + sides[1] > sides[2]
|
||||||
|
&& sides[0] + sides[2] > sides[1]
|
||||||
|
&& sides[1] + sides[2] > sides[0]
|
||||||
|
{
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
0
|
||||||
|
})
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.map(|line| {
|
||||||
|
line.split_whitespace()
|
||||||
|
.map(|side| side.parse::<u32>().unwrap())
|
||||||
|
.collect::<Vec<u32>>()
|
||||||
|
})
|
||||||
|
.collect::<Vec<Vec<u32>>>()
|
||||||
|
.chunks(3)
|
||||||
|
.map(|line_triple| {
|
||||||
|
(0..3)
|
||||||
|
.map(|triangle_idx| {
|
||||||
|
if line_triple[0][triangle_idx] + line_triple[1][triangle_idx]
|
||||||
|
> line_triple[2][triangle_idx]
|
||||||
|
&& line_triple[0][triangle_idx] + line_triple[2][triangle_idx]
|
||||||
|
> line_triple[1][triangle_idx]
|
||||||
|
&& line_triple[1][triangle_idx] + line_triple[2][triangle_idx]
|
||||||
|
> line_triple[0][triangle_idx]
|
||||||
|
{
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
0
|
||||||
|
})
|
||||||
|
.sum::<u32>()
|
||||||
|
})
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = " 5 10 25";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 0);
|
||||||
|
}
|
||||||
|
}
|
119
y2016/src/days/d4.rs
Normal file
119
y2016/src/days/d4.rs
Normal file
@@ -0,0 +1,119 @@
|
|||||||
|
use std::collections::HashMap;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.map(|line| {
|
||||||
|
let name = get_name(line);
|
||||||
|
let id = get_id(line);
|
||||||
|
let checksum = get_checksum(line);
|
||||||
|
let stats = get_freq_and_position(&name);
|
||||||
|
let mut sorted_stats = stats.into_iter().collect::<Vec<(char, i32)>>();
|
||||||
|
sorted_stats.sort_by(|(a, a_freq), (b, b_freq)| match b_freq.cmp(a_freq) {
|
||||||
|
std::cmp::Ordering::Less => std::cmp::Ordering::Less,
|
||||||
|
std::cmp::Ordering::Greater => std::cmp::Ordering::Greater,
|
||||||
|
std::cmp::Ordering::Equal => a.cmp(b),
|
||||||
|
});
|
||||||
|
for (char, _stats) in sorted_stats.into_iter().take(5) {
|
||||||
|
if !checksum.contains(char) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
id
|
||||||
|
})
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> String {
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.filter(|line| {
|
||||||
|
let name = get_name(line);
|
||||||
|
let checksum = get_checksum(line);
|
||||||
|
let stats = get_freq_and_position(&name);
|
||||||
|
let mut sorted_stats = stats.into_iter().collect::<Vec<(char, i32)>>();
|
||||||
|
sorted_stats.sort_by(|(a, a_freq), (b, b_freq)| match b_freq.cmp(a_freq) {
|
||||||
|
std::cmp::Ordering::Less => std::cmp::Ordering::Less,
|
||||||
|
std::cmp::Ordering::Greater => std::cmp::Ordering::Greater,
|
||||||
|
std::cmp::Ordering::Equal => a.cmp(b),
|
||||||
|
});
|
||||||
|
for (char, _stats) in sorted_stats.into_iter().take(5) {
|
||||||
|
if !checksum.contains(char) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
true
|
||||||
|
})
|
||||||
|
.map(|line| {
|
||||||
|
let name = get_name(line);
|
||||||
|
let id = get_id(line);
|
||||||
|
format!("{}: {id}", rot(&name, id))
|
||||||
|
})
|
||||||
|
.collect::<Vec<String>>()
|
||||||
|
.join("\n")
|
||||||
|
}
|
||||||
|
|
||||||
|
fn rot(name: &str, count: u32) -> String {
|
||||||
|
let mut decrypted = Vec::new();
|
||||||
|
for &byte in name.as_bytes() {
|
||||||
|
if byte == b'-' {
|
||||||
|
decrypted.push(b' ');
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
let shift = (byte - b'a') as u32 + count;
|
||||||
|
decrypted.push((shift % 26) as u8 + b'a');
|
||||||
|
}
|
||||||
|
String::from_utf8(decrypted).unwrap()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn get_name(room: &str) -> String {
|
||||||
|
room.rsplit_once("-").unwrap().0.to_string()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn get_id(room: &str) -> u32 {
|
||||||
|
let id_start = room.rfind("-").unwrap() + 1;
|
||||||
|
let id_end = room.find("[").unwrap();
|
||||||
|
room[id_start..id_end].parse().unwrap()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn get_checksum(room: &str) -> String {
|
||||||
|
let id_start = room.find("[").unwrap() + 1;
|
||||||
|
room[id_start..room.len() - 1].to_string()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn get_freq_and_position(name: &str) -> HashMap<char, i32> {
|
||||||
|
let mut freq = HashMap::new();
|
||||||
|
for char in name.chars() {
|
||||||
|
if char == '-' {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
freq.entry(char)
|
||||||
|
.and_modify(|count| {
|
||||||
|
*count += 1;
|
||||||
|
})
|
||||||
|
.or_insert(1);
|
||||||
|
}
|
||||||
|
freq
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::{rot, *};
|
||||||
|
|
||||||
|
const INPUT: &str = "aaaaa-bbb-z-y-x-123[abxyz]
|
||||||
|
a-b-c-d-e-f-g-h-987[abcde]
|
||||||
|
not-a-real-room-404[oarel]
|
||||||
|
totally-real-room-200[decoy]";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, 1514);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let res = rot("qzmt-zixmtkozy-ivhz", 343);
|
||||||
|
assert_eq!(res, "very encrypted name".to_string());
|
||||||
|
}
|
||||||
|
}
|
83
y2016/src/days/d5.rs
Normal file
83
y2016/src/days/d5.rs
Normal file
@@ -0,0 +1,83 @@
|
|||||||
|
use std::io::{stdout, Write};
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> String {
|
||||||
|
let mut password = String::new();
|
||||||
|
let mut n = 0;
|
||||||
|
let mut col = 1;
|
||||||
|
print!("________");
|
||||||
|
loop {
|
||||||
|
let hash = md5::compute(format!("{input}{n}"));
|
||||||
|
let hash = format!("{hash:x}");
|
||||||
|
let mut chars = hash.chars().skip(5);
|
||||||
|
let char = chars.next().unwrap();
|
||||||
|
print!("\x1b[{col}G{char}");
|
||||||
|
if hash.split_at(5).0 == "00000" {
|
||||||
|
col += 1;
|
||||||
|
password.push(char);
|
||||||
|
}
|
||||||
|
if password.len() == 8 {
|
||||||
|
println!();
|
||||||
|
return password;
|
||||||
|
}
|
||||||
|
n += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> String {
|
||||||
|
let mut password = vec!['_'; 8];
|
||||||
|
let mut n = 0;
|
||||||
|
print!("________");
|
||||||
|
loop {
|
||||||
|
if !password.contains(&'_') {
|
||||||
|
println!();
|
||||||
|
return password.into_iter().collect();
|
||||||
|
}
|
||||||
|
let hash = md5::compute(format!("{input}{n}"));
|
||||||
|
let hash = format!("{hash:x}");
|
||||||
|
if hash.split_at(5).0 == "00000" {
|
||||||
|
let mut chars = hash.chars().skip(5);
|
||||||
|
let position = match chars.next().unwrap().to_digit(10) {
|
||||||
|
Some(position) => {
|
||||||
|
if position > 7 {
|
||||||
|
n += 1;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if password[position as usize] != '_' {
|
||||||
|
n += 1;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
position
|
||||||
|
}
|
||||||
|
None => {
|
||||||
|
n += 1;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
let char = chars.next().unwrap();
|
||||||
|
print!("\x1b[{}G{char}", position + 1);
|
||||||
|
//println!("{}", password.clone().into_iter().collect::<String>());
|
||||||
|
let _ = stdout().flush();
|
||||||
|
password[position as usize] = char;
|
||||||
|
}
|
||||||
|
n += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "abc";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, "18f47a30".to_string());
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, "05ace8e3".to_string());
|
||||||
|
}
|
||||||
|
}
|
73
y2016/src/days/d6.rs
Normal file
73
y2016/src/days/d6.rs
Normal file
@@ -0,0 +1,73 @@
|
|||||||
|
use std::collections::HashMap;
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str) -> String {
|
||||||
|
let line_len = input.find("\n").unwrap();
|
||||||
|
let mut rows: Vec<HashMap<char, u32>> = vec![HashMap::new(); line_len];
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
for (idx, chara) in line.chars().enumerate() {
|
||||||
|
rows[idx]
|
||||||
|
.entry(chara)
|
||||||
|
.and_modify(|count| *count += 1)
|
||||||
|
.or_insert(1);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
let mut res = String::new();
|
||||||
|
for row in rows {
|
||||||
|
let most_common = row.iter().max_by(|a, b| a.1.cmp(b.1)).unwrap().0;
|
||||||
|
res.push(*most_common);
|
||||||
|
}
|
||||||
|
res
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> String {
|
||||||
|
let line_len = input.find("\n").unwrap();
|
||||||
|
let mut rows: Vec<HashMap<char, u32>> = vec![HashMap::new(); line_len];
|
||||||
|
input.lines().for_each(|line| {
|
||||||
|
for (idx, chara) in line.chars().enumerate() {
|
||||||
|
rows[idx]
|
||||||
|
.entry(chara)
|
||||||
|
.and_modify(|count| *count += 1)
|
||||||
|
.or_insert(1);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
let mut res = String::new();
|
||||||
|
for row in rows {
|
||||||
|
let most_common = row.iter().max_by(|a, b| b.1.cmp(a.1)).unwrap().0;
|
||||||
|
res.push(*most_common);
|
||||||
|
}
|
||||||
|
res
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "eedadn
|
||||||
|
drvtee
|
||||||
|
eandsr
|
||||||
|
raavrd
|
||||||
|
atevrs
|
||||||
|
tsrnev
|
||||||
|
sdttsa
|
||||||
|
rasrtv
|
||||||
|
nssdts
|
||||||
|
ntnada
|
||||||
|
svetve
|
||||||
|
tesnvt
|
||||||
|
vntsnd
|
||||||
|
vrdear
|
||||||
|
dvrsen
|
||||||
|
enarar";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT);
|
||||||
|
assert_eq!(result, *"easter");
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, *"advent");
|
||||||
|
}
|
||||||
|
}
|
163
y2016/src/days/d7.rs
Normal file
163
y2016/src/days/d7.rs
Normal file
@@ -0,0 +1,163 @@
|
|||||||
|
pub fn process_part1(input: &str) -> u32 {
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.map(|line| if is_tls(line) { 1 } else { 0 })
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(input: &str) -> u32 {
|
||||||
|
input
|
||||||
|
.lines()
|
||||||
|
.map(|line| if is_ssl(line) { 1 } else { 0 })
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
fn is_tls(ipv7: &str) -> bool {
|
||||||
|
let mut abba = false;
|
||||||
|
let mut part = String::new();
|
||||||
|
for chara in ipv7.chars() {
|
||||||
|
if chara == '[' {
|
||||||
|
if contains_abba(&part) {
|
||||||
|
abba = true;
|
||||||
|
}
|
||||||
|
part.clear();
|
||||||
|
} else if chara == ']' {
|
||||||
|
if contains_abba(&part) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
part.clear();
|
||||||
|
} else {
|
||||||
|
part.push(chara);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if contains_abba(&part) {
|
||||||
|
abba = true;
|
||||||
|
}
|
||||||
|
abba
|
||||||
|
}
|
||||||
|
|
||||||
|
fn contains_abba(part: &str) -> bool {
|
||||||
|
if part.len() < 4 {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
for window in part.chars().collect::<Vec<char>>().windows(4) {
|
||||||
|
if window[0] == window[3] && window[1] == window[2] && window[0] != window[1] {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
false
|
||||||
|
}
|
||||||
|
|
||||||
|
fn is_ssl(ipv7: &str) -> bool {
|
||||||
|
let mut abas = Vec::new();
|
||||||
|
let mut babs = Vec::new();
|
||||||
|
let mut part = String::new();
|
||||||
|
for chara in ipv7.chars() {
|
||||||
|
if chara == '[' {
|
||||||
|
if let Some(additional_aba) = get_aba_or_bab(&part) {
|
||||||
|
abas.extend_from_slice(&additional_aba);
|
||||||
|
}
|
||||||
|
part.clear();
|
||||||
|
} else if chara == ']' {
|
||||||
|
if let Some(additional_bab) = get_aba_or_bab(&part) {
|
||||||
|
babs.extend_from_slice(&additional_bab);
|
||||||
|
}
|
||||||
|
part.clear();
|
||||||
|
} else {
|
||||||
|
part.push(chara);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if let Some(additional_aba) = get_aba_or_bab(&part) {
|
||||||
|
abas.extend_from_slice(&additional_aba);
|
||||||
|
}
|
||||||
|
for aba in abas {
|
||||||
|
for bab in babs.iter() {
|
||||||
|
let aba = aba.chars().collect::<Vec<char>>();
|
||||||
|
let bab = bab.chars().collect::<Vec<char>>();
|
||||||
|
if aba[0] == bab[1] && aba[1] == bab[0] {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
false
|
||||||
|
}
|
||||||
|
|
||||||
|
fn get_aba_or_bab(part: &str) -> Option<Vec<String>> {
|
||||||
|
if part.len() < 3 {
|
||||||
|
return None;
|
||||||
|
}
|
||||||
|
let mut aba_bab: Vec<String> = Vec::new();
|
||||||
|
for window in part.chars().collect::<Vec<char>>().windows(3) {
|
||||||
|
if window[0] == window[2] {
|
||||||
|
aba_bab.push(window.iter().collect());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if aba_bab.is_empty() {
|
||||||
|
None
|
||||||
|
} else {
|
||||||
|
Some(aba_bab)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT_1: &str = "abba[mnop]qrst";
|
||||||
|
const INPUT_2: &str = "abcd[bddb]xyyx";
|
||||||
|
const INPUT_3: &str = "aaaa[qwer]tyui";
|
||||||
|
const INPUT_4: &str = "ioxxoj[asdfgh]zxcvbn";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1_1() {
|
||||||
|
let result = is_tls(INPUT_1);
|
||||||
|
assert!(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1_2() {
|
||||||
|
let result = is_tls(INPUT_2);
|
||||||
|
assert!(!result);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1_3() {
|
||||||
|
let result = is_tls(INPUT_3);
|
||||||
|
assert!(!result);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1_4() {
|
||||||
|
let result = is_tls(INPUT_4);
|
||||||
|
assert!(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
const INPUT_5: &str = "aba[bab]xyz";
|
||||||
|
const INPUT_6: &str = "xyx[xyx]xyx";
|
||||||
|
const INPUT_7: &str = "aaa[kek]eke";
|
||||||
|
const INPUT_8: &str = "zazbz[bzb]cdb";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2_1() {
|
||||||
|
let result = is_ssl(INPUT_5);
|
||||||
|
assert!(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2_2() {
|
||||||
|
let result = is_ssl(INPUT_6);
|
||||||
|
assert!(!result);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2_3() {
|
||||||
|
let result = is_ssl(INPUT_7);
|
||||||
|
assert!(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2_4() {
|
||||||
|
let result = is_ssl(INPUT_8);
|
||||||
|
assert!(result);
|
||||||
|
}
|
||||||
|
}
|
100
y2016/src/days/d8.rs
Normal file
100
y2016/src/days/d8.rs
Normal file
@@ -0,0 +1,100 @@
|
|||||||
|
use itertools::Itertools;
|
||||||
|
|
||||||
|
enum Instruction {
|
||||||
|
Rect(u32, u32),
|
||||||
|
ShiftRight(u32, u32),
|
||||||
|
ShiftDown(u32, u32),
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part1(input: &str, grid_size: (usize, usize)) -> i32 {
|
||||||
|
let instructions = input
|
||||||
|
.lines()
|
||||||
|
.map(parse_instruction)
|
||||||
|
.map(|option| option.unwrap())
|
||||||
|
.collect_vec();
|
||||||
|
let mut grid = vec![vec!['.'; grid_size.0]; grid_size.1];
|
||||||
|
for instrution in instructions {
|
||||||
|
match instrution {
|
||||||
|
Instruction::Rect(width, height) => {
|
||||||
|
for row in 0..=height {
|
||||||
|
for col in 0..=width {
|
||||||
|
grid[row as usize][col as usize] = '#';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Instruction::ShiftRight(row, by) => grid[row as usize].rotate_right(by as usize),
|
||||||
|
Instruction::ShiftDown(col, by) => {
|
||||||
|
let mut col_items = grid.iter().map(|row| row[col as usize]).collect_vec();
|
||||||
|
col_items.rotate_right(by as usize);
|
||||||
|
for (row, pixel) in col_items.iter().enumerate() {
|
||||||
|
grid[row][col as usize] = *pixel;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
for row in grid.clone() {
|
||||||
|
println!("{}", row.iter().join(""));
|
||||||
|
}
|
||||||
|
println!();
|
||||||
|
}
|
||||||
|
grid.iter()
|
||||||
|
.map(|row| {
|
||||||
|
row.iter()
|
||||||
|
.map(|pixel| if *pixel == '#' { 1 } else { 0 })
|
||||||
|
.sum::<i32>()
|
||||||
|
})
|
||||||
|
.sum()
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn process_part2(_input: &str) -> i32 {
|
||||||
|
0
|
||||||
|
}
|
||||||
|
|
||||||
|
fn parse_instruction(inst: &str) -> Option<Instruction> {
|
||||||
|
if inst.contains("rect") {
|
||||||
|
let (_, axb) = inst.split_once(" ").unwrap();
|
||||||
|
let (a, b) = axb.split_once("x").unwrap();
|
||||||
|
return Some(Instruction::Rect(
|
||||||
|
a.parse::<u32>().unwrap() - 1,
|
||||||
|
b.parse::<u32>().unwrap() - 1,
|
||||||
|
));
|
||||||
|
}
|
||||||
|
if inst.contains("rotate row y") {
|
||||||
|
let (_, abyb) = inst.split_once("=").unwrap();
|
||||||
|
let (a, b) = abyb.split_once(" by ").unwrap();
|
||||||
|
return Some(Instruction::ShiftRight(
|
||||||
|
a.parse().unwrap(),
|
||||||
|
b.parse().unwrap(),
|
||||||
|
));
|
||||||
|
}
|
||||||
|
if inst.contains("rotate column x") {
|
||||||
|
let (_, abyb) = inst.split_once("=").unwrap();
|
||||||
|
let (a, b) = abyb.split_once(" by ").unwrap();
|
||||||
|
return Some(Instruction::ShiftDown(
|
||||||
|
a.parse().unwrap(),
|
||||||
|
b.parse().unwrap(),
|
||||||
|
));
|
||||||
|
}
|
||||||
|
None
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const INPUT: &str = "rect 3x2
|
||||||
|
rotate column x=1 by 1
|
||||||
|
rotate row y=0 by 4
|
||||||
|
rotate column x=1 by 1";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part1() {
|
||||||
|
let result = process_part1(INPUT, (7, 3));
|
||||||
|
assert_eq!(result, 6);
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn part2() {
|
||||||
|
let result = process_part2(INPUT);
|
||||||
|
assert_eq!(result, 0);
|
||||||
|
}
|
||||||
|
}
|
15
y2016/src/days/mod.rs
Normal file
15
y2016/src/days/mod.rs
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
pub mod d1;
|
||||||
|
|
||||||
|
pub mod d2;
|
||||||
|
|
||||||
|
pub mod d3;
|
||||||
|
|
||||||
|
pub mod d4;
|
||||||
|
|
||||||
|
pub mod d5;
|
||||||
|
|
||||||
|
pub mod d6;
|
||||||
|
|
||||||
|
pub mod d7;
|
||||||
|
|
||||||
|
pub mod d8;
|
@@ -0,0 +1 @@
|
|||||||
|
pub mod days;
|
||||||
|
@@ -0,0 +1 @@
|
|||||||
|
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user