IBM Interview Question

it was a hackerank, sql, python