PetroApp interview question

2 Problems SQL and DSA