From 5201dcf0bc212736d9bc70133a5e030b8a93afed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20M=C3=BCller?= Date: Wed, 21 May 2025 20:23:42 +0200 Subject: [PATCH] Fix day 17 division instruction (it's just a shift) --- src/extra/ChronospatialComputerInstruction.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/extra/ChronospatialComputerInstruction.cpp b/src/extra/ChronospatialComputerInstruction.cpp index 6053f9b..1979d83 100644 --- a/src/extra/ChronospatialComputerInstruction.cpp +++ b/src/extra/ChronospatialComputerInstruction.cpp @@ -45,7 +45,7 @@ ChronospatialComputerDivisionInstruction::ChronospatialComputerDivisionInstructi void ChronospatialComputerDivisionInstruction::runValue(ChronospatialComputerState& state, const int operandValue) const { - state.registers[destination_] = state.registers[0] / Math::ipow(2, operandValue); + state.registers[destination_] = state.registers[0] >> operandValue; state.instructionPointer += 2; }