Clarify part 1 strategy

This commit is contained in:
Adam Millerchip 2020-12-10 00:36:55 +09:00
parent 8f4d06e24d
commit 0e60744957

View file

@ -19,7 +19,7 @@ Every time the window slides, I decided to sort it, which means I could take the
* When selecting the first number in the pair, stop early if added to the first number in the preamble it's * When selecting the first number in the pair, stop early if added to the first number in the preamble it's
greater than the target, because we know the rest of the numbers are also too large. greater than the target, because we know the rest of the numbers are also too large.
* Similarly can do the same when checking for the second number in the pair. * Similarly can do the same when checking for the second number in the pair.
* Avoids comparing pairs we already compared. * Avoids comparing pairs we already compared, by only searching from the location of the first value onwards.
+--------+ +--------+