Synechron interview question

Writing a SERVLET code .. sudden and unexpected..!