IBM interview question

question related to java and javascript