projects
/
advent-of-code-19.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c2a0cc1
)
Removed a redundant filter
author
Neil Smith
<neil.git@njae.me.uk>
Wed, 4 Dec 2019 08:09:57 +0000
(08:09 +0000)
committer
Neil Smith
<neil.git@njae.me.uk>
Wed, 4 Dec 2019 08:09:57 +0000
(08:09 +0000)
advent04/src/advent04.hs
patch
|
blob
|
history
diff --git
a/advent04/src/advent04.hs
b/advent04/src/advent04.hs
index 9066cbbd2744d58d54cf01aabef5733df24d17da..ac7c1756ba0db88c4d6badc0f240316625a846a0 100644
(file)
--- a/
advent04/src/advent04.hs
+++ b/
advent04/src/advent04.hs
@@
-9,7
+9,7
@@
upperLimit = 675810
part1 = length $ filter inRange $ filter adjacentSame candidates
-part2 = length $ filter i
solatedAdjacentSame $ filter inRange $ filter a
djacentSame candidates
+part2 = length $ filter i
nRange $ filter isolatedA
djacentSame candidates
inRange digits = n >= lowerLimit && n <= upperLimit
where n = numify digits