Move input out of redundant 2018 dir; Address warnings

This commit is contained in:
Wesley Moore 2018-12-06 08:25:12 +11:00
parent e1cf4d7ba3
commit 709bb0e8ed
No known key found for this signature in database
GPG key ID: BF67766C0BC2D0EE
8 changed files with 6 additions and 5 deletions

1
2018/input/day5.txt Normal file

File diff suppressed because one or more lines are too long

View file

@ -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();

View file

@ -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()

View file

@ -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()