Genpact interview question

Hacker Rank test - 2 related to java programming and 2 are from SQL queries