Skip to main content

Module day18

Module day18 

Source
Expand description

ยงBoiling Boulders

The lava droplet is a fixed size so we can use a one-dimensional fixed-size array to store the cube data for speed.

For part two we use the flood fill algorithm starting from any corner to fill the outside space with water. We then use the same exposed edge counting approach as part one, but only considering faces that touch a water drop.

Constantsยง

NEIGHBORS ๐Ÿ”’
SIZE ๐Ÿ”’

Functionsยง

count ๐Ÿ”’
parse
part1
part2