HCLTech interview question

It was Java Technical