part2 :: [Int] -> Int
part2 nums = countIncreasing $ map sum windows
- where windows = filter (\w -> length w == 3) $ map (take 3) $ tails nums
+ where windows = filter ((== 3) . length) $ map (take 3) $ tails nums
countIncreasing :: [Int] -> Int
-countIncreasing nums = length $ filter (> 0) $ zipWith (-) (tail nums) nums
+-- countIncreasing nums = length $ filter (> 0) $ zipWith (-) (tail nums) nums
+countIncreasing nums = length $ filter (uncurry (>)) $ zip (tail nums) nums