SLK Group interview question

program to reverse a number