UST Interview Question

parking lot problem for coding