Solution for SecondGreatLow problem