Kytes interview question

Collection, sql, oops concepts, logical question