diff --git a/9.rkt b/9.rkt index 498ec44..37a6e55 100644 --- a/9.rkt +++ b/9.rkt @@ -21,7 +21,7 @@ ;; continuously sort the part of the vector below the iterator, and call contains-sum? (define (part1 vec) (for*/first ([i (in-range 25 (vector-length vec))] [x (in-value (vector-ref vec i))] - #:unless (contains-sum? vec 0 i x)) + #:unless (contains-sum? (vector-copy vec (- i 25) i) 0 25 x)) (cons i x))) (define (part2 vec pt1-ans)