Nasdaq Interview Question

basic SQL joins, python questions