Tuesday, August 19, 2014

COJ 1484. Hotest Mountain

This is a simple problem of calculating maximum. This is how you do it, you take a variable max and give it a value of the first element assuming that it is the maximum. Then you loop over array and check if there is one grater than the current maximum, if there is , then you update the value of MAX and also keep track of the position.


       FULL SOURCE CODE 

No comments:

Post a Comment