Code for challenges done on www.hackerrank.com