KPMG interview question

Easy programs and few SQL quesries.