
Find the first row of the map that is water all the way across.
September 2012. Apple drops Google Maps from the iPhone and ships its own, and the screenshots start within hours: a farm outside Dublin labelled as an airport, bridges melting into the rivers they crossed. Tim Cook apologised in an open letter and pointed people at the competition. The ground underneath was wrong. Find the row the river runs through.
river_row({0,0,1,1, 1,1,1,1, 1,1,0,0, 1,1,1,1}, 4, 4)Expected result
1For your own tracking. Tests grade your code.
river_row({0,1,0, 1,0,1}, 3, 2)Expected result
-1river_row({1,1,1, 0,1,1}, 3, 2)Expected result
0Expected files
terrain.cAllowed functions
None. Write every helper yourself.
