CodeChef Starters 112 Solution Discussion (finished)