javascript logical interview questions and answers