Question: I need help with this c++ function, I do not need a int main() function in it just a singular function. Write a function floodMap

I need help with this c++ function, I do not need a int main() function in it just a singular function.

I need help with this c++ function, I do not need a

Write a function floodMap which takes three arguments, a two-dimensional array of doubles indicating the height of the terrain at a particular point in space (assume that there are 4 columns), an int indicating the number of rows in the map, and a double indicating the current water level. The function should print out a "map" of which points in the array are below the water level. In particular, each position at or below the water level will be represented with a and each position above the water level will be represented with a Your function should be named floodMap Your function should take three parameters. o o o Atwo-dimensional array of doubles with 4 columns. The number of rows in the array. A double indicating the current water level Your function should print a flood map as described. Examples double map [1] [4] 5.0, 7.6, 3.1, 292)) * *_ floodMap (map, 1, 6.0) double map [2] [4] {(0.2, 0.8, 0.8, 0.2), = -- (0.2, 0.2, 0.8, 0.5) floodMap (map, 2, 0.0) double map [2] 4]-o.2, 0.8, 0.8, 0.2* (0.2, 0.2, 0.8, 0.5) _* floodMap (map, 2, 0.5) double map [2] [4] -0.2, 0.8, 0.8, 0.2], 0.2, 0.2, 0.8, 0.51* floodMap (map, 2, 1.0)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!