Fei's Playground home

Interview Question: Parking Lot

Basic Question


I’m the owner of a parking lot empire. I’m still pretty small - I only have 3 lots in downtown, but my visions are grand. As such, I’ve hired you to design and build an automated system for managing my parking lots. Assume that you have access to all the latest in ticket-giving and ticket-accepting machines, a sensor network built into the parking lot, and programmable signs to give directions to customers. I want to charge customers by the amount of space they use in the lot (area) and the length of time they use the lot (time).


A good candidate should start asking you questions at this point, determining the bounds of the problem and getting clarifying information (this is good). But if not, help focus them on a couple specific use cases:

The candidate should then dive into the problem and start scoping out objects and methods and such. Some candidates with DB backgrounds tend to go towards DBs and tables, others stay at the OO level. It’s up to the interviewer to either tell the candidate ahead of time which version they’d like the candidate to do or just accept either solution.

Checklist of things that the candidate might design:

Want more?

If you have more time, there are a number of places to move on from here, like:

Calibration


Here are some general thoughts on how I calibrate answers.

Additional note


Fork me on GitHub