AdventOfCode-2018/day1_1.cr

5 lines
88 B
Crystal

puts File.read("day1").split("\n")
.select { |it| !it.empty? }
.map(&.to_i)
.sum