remove another useless 100
This commit is contained in:
@@ -17,7 +17,7 @@ public class Day01 {
|
||||
String instruction = scanner.nextLine();
|
||||
int change = Integer.parseInt(instruction.substring(1));
|
||||
dial = switch (instruction.charAt(0)) {
|
||||
case 'L' -> (dial - change + 100) % 100;
|
||||
case 'L' -> (dial - change) % 100;
|
||||
case 'R' -> (dial + change) % 100;
|
||||
default -> dial; // impossible
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user