Skip to content

Commit 7f736d8

Browse files
committed
Fix tiny mistake
1 parent 742ee40 commit 7f736d8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

content/posts/the_silly_solution.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ int silly2(int n)
127127
```
128128

129129
Before we get into the next section, I want to explain how exactly it finds the number of fours. First, it divides `n`
130-
by 4 and sets it equal to `n4`. But this is not enough, because not every number is not divisible by 4 (duh). So it also calculates `n % 4`, and
130+
by 4 and sets it equal to `n4`. But this is not enough, because not every number is divisible by 4 (duh). So it also calculates `n % 4`, and
131131
sets it equal to `d` (I avoided using modulus operator and went with `n-n4*4` there because it is faster, yes I am obsessed
132132
with tiny and probably negligible speed improvements). Since this value can take values 0, 1, 2 and 3; I manually counted how many fours I had to remove
133133
in order for the difference to be divisible by 5:

0 commit comments

Comments
 (0)