public override string First(string input) { var alu = new Alu(input); alu.ExecuteProgram(haltOnReceive: true); return(alu.GetRegValue(_RECEIVE).ToString()); }
public override string First(string input) { var alu = new Alu(input); alu.ExecuteProgram(); return(alu.DebugCount["mul"].ToString()); }
public override string First(string input) { var alu = new Alu(input); alu.ExecuteProgram(); return(alu.Registers["a"].ToString()); }
public override string Second(string input) { // 479009360 : took 29 minutes var alu = new Alu(input); alu.Registers["a"] = 12; alu.ExecuteProgram(); return(alu.Registers["a"].ToString()); }
public override string Second(string input) { //return SecondInCSharp(); var alu = new Alu(PatchProgram(input)); alu.Registers["a"] = 1; alu.ExecuteProgram(); return(alu.Registers["h"].ToString()); }
public override string First(string input) { var alu = new Alu(input); for (int a = 0; a < 100000; a++) { alu.Reset(); alu.Registers["a"] = a; alu.ExecuteProgram(); if (alu.Outputs.Count > 0) { return(a.ToString()); } } return("NOPE"); }