You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
343 B
19 lines
343 B
mod cpu;
|
|
mod alu;
|
|
|
|
use cpu::Cpu;
|
|
use alu::Alu;
|
|
|
|
pub const DEBUG: bool = false;
|
|
|
|
fn main() {
|
|
let mut cpu = Cpu::new();
|
|
cpu.read_program_from_file("challenge.bin");
|
|
let result = cpu.execute();
|
|
if result.is_ok() {
|
|
println!("Execution successful!");
|
|
} else {
|
|
println!("Err: {}", result.err().unwrap())
|
|
}
|
|
}
|
|
|
|
|