KPMG interview question

Logical Program And Java OOPS and Collection