Author: Varun Singh
Given the height of N minions, find the height of the tallest minion
Scan the height of all the minions and find the largest number among them.
For each test case, scan the height of all the minions one by one and keep a record of the largest number. The largest number is the answer.
Alternatively, one can store all the numbers in an array, sort them in descending order and print the first element of the array. Although this will take slightly longer than the previous solution but given the input size, it won’t make any noticeable difference.
Author’s solution can be found here.