BeatO interview question

Logical questions SQL query writing