HCLTech interview question

Java and some java formwork