diff --git a/src/main.rs b/src/main.rs index 5b0d72f..76a7e90 100644 --- a/src/main.rs +++ b/src/main.rs @@ -16,9 +16,9 @@ impl Program { fn from_string(program: String) -> Program { let mut op_list: Vec = Vec::new(); - for opcode in program.split(" ").collect::>() { - let mut new_op = opcode.to_owned(); - new_op = new_op.replace("\n", ""); + for opcode in program.split("\n").collect::>() { + let new_op = opcode.to_owned(); + // new_op = new_op.replace("\n", ""); if new_op.len() != 0 { op_list.push(new_op.to_owned());