Facebook Java Online Interview Question
Difficulty: EASYCategory: InterviewExperienceFrequency: 1Asked On 2021-02-08Added By Anonymous
Source: Link
Company: Meta
Role: unknown
Interview Stage: Online Interview
Location: unknown
Year: unknown
Original Post Content:
Keep track or report average transit times between stations in a subway or public tranportation system.
Each rider has transit card which they swipe in while entering a station and swipe out when leaving the station. Cards have unique identification numbers and riders dont lose or share their cards.
To implement a class that stores entry, exit and swipe info like time, card, station and return the average transit time between any pair of stations.