CodeChef Starters 154 Solution Discussion (finished)