Company: Toast_27april
Difficulty: medium
Republic day parade Problem Description Senior commander John is preparing for the Republic Day parade and wants to select three officers to lead the parade. He asks all his officers to stand in a line. All the officers are of distinct height. John follows a strict selection rule: He starts from the first officer in the line and decides whether to select him or not. He does so for every officer in the line as he moves forward. If he selects an officer, then every next selected officer must be shorter than the previously selected one. He makes sure he has selected exactly three officers by the time he has reached the end of the line. Given that there are N officers in the line, your task is to determine the number of ways he can select three officers following the above rule. Complete the function solve() provided in the editor. The function takes the following two parameters and returns an integer. N : Representing the number of officers. Height : Representing an array of heights (in c