// https://adventofcode.com/2024/day/4 // // Run command: cargo run ./input.txt use std::env; use std::error::Error; use std::fs::File; mod crossword; use crate::crossword::Crossword; fn main() -> Result<(), Box> { // Handle command input let args: Vec = env::args().collect(); if args.len() != 2 { panic!( "{} must be run with a single argument of files name!", &args[0] ) } let input_file_string = &args[1]; let crossword = Crossword::new(File::open(input_file_string)?)?; println!("{}", crossword); Ok(()) }