Synoptek interview question

SQL Queries and OOPs Concepts