mirror of
https://github.com/wezm/advent-of-code.git
synced 2024-12-18 10:19:55 +00:00
Move input out of redundant 2018 dir; Address warnings
This commit is contained in:
parent
e1cf4d7ba3
commit
709bb0e8ed
8 changed files with 6 additions and 5 deletions
1
2018/input/day5.txt
Normal file
1
2018/input/day5.txt
Normal file
File diff suppressed because one or more lines are too long
|
@ -1,8 +1,8 @@
|
|||
use std::io::{self, BufRead, BufReader};
|
||||
use std::io::{BufRead, BufReader};
|
||||
use std::fs::{self, File};
|
||||
use std::collections::HashSet;
|
||||
|
||||
const INPUT: &str = "input/2018/day1.txt";
|
||||
const INPUT: &str = "input/day1.txt";
|
||||
|
||||
fn main() {
|
||||
part1();
|
||||
|
|
|
@ -2,7 +2,7 @@ use std::collections::HashMap;
|
|||
use std::fs;
|
||||
|
||||
fn main() {
|
||||
let input = fs::read_to_string("input/2018/day2.txt").expect("input");
|
||||
let input = fs::read_to_string("input/day2.txt").expect("input");
|
||||
part1(&input);
|
||||
part2(&input);
|
||||
}
|
||||
|
@ -44,7 +44,7 @@ fn part2(input: &str) {
|
|||
|acc, (chr1, chr2)| if chr1 != chr2 { acc + 1 } else { acc },
|
||||
);
|
||||
|
||||
if (number_differing == 1) {
|
||||
if number_differing == 1 {
|
||||
println!("{} and {} differ by 1 char", line, other);
|
||||
let common: String = line
|
||||
.chars()
|
||||
|
|
|
@ -22,7 +22,7 @@ struct Claim {
|
|||
}
|
||||
|
||||
fn main() {
|
||||
let input = fs::read_to_string("input/2018/day3.txt").expect("input");
|
||||
let input = fs::read_to_string("input/day3.txt").expect("input");
|
||||
|
||||
let claims = input
|
||||
.lines()
|
||||
|
|
Loading…
Reference in a new issue