Karthik's submission of A - Appearance Count | CodeChef