Code for interview questions