Zeta | LLD | SDE-2
Anonymous User
827

Toll Service

On a daily basis, N types of vehicles that are passing from Y numbers TollPlazas. 1 TollPlaza can have X number of toll booths. Users need to buy the pass to cross the tollBooth.
Below are pass types->

  1. One way pass
  2. Round Trip pass
  3. Daily pass
  4. Weekly pass

Mandatory
Issue the pass
Validating pass

As a TollBooth owner, I can see below points ->

  1. Total collection at the day end.
  2. Total number of vehicles at the day end.
  3. Number of passes issued to customers.

Scope of this problem ->

  1. N = 2. We can assume 2 types of vehicle passes from TollPlaza.
  2. Y = 5. We can assume 5 toll plaza(5 different places).
  3. X = 3. We can assume 1 toll plaza has 3 tollBooths.

Below are few coding points ->

  1. We can use any kind of database. Example -> Sql, NoSql, InMemory
  2. We can use any language.Example -> Java, PHP, Javascript, Python
  3. We can use any IDE. Example -> IntelliJ, Eclipse, Notepad

Can someone answer this, I was sked this in zeta interview?

Comments (2)