|
|
@ -4,7 +4,7 @@ use errors::*;
|
|
|
|
pub fn solve(input: &str) -> Result<String> {
|
|
|
|
pub fn solve(input: &str) -> Result<String> {
|
|
|
|
let instructions: Instructions = input.parse()?;
|
|
|
|
let instructions: Instructions = input.parse()?;
|
|
|
|
let mut registers = Registers::new();
|
|
|
|
let mut registers = Registers::new();
|
|
|
|
registers[Register::A] = 7;
|
|
|
|
registers[Register::A] = 12;
|
|
|
|
let assembunny = Assembunny{registers: registers, instructions: instructions};
|
|
|
|
let assembunny = Assembunny{registers: registers, instructions: instructions};
|
|
|
|
|
|
|
|
|
|
|
|
let registers = assembunny.last().ok_or("")?;
|
|
|
|
let registers = assembunny.last().ok_or("")?;
|
|
|
|