Panda Guru LogoPanda
Guru

Uber | OA | SE2 | India

Round 1

Questions:

  1. You are given a list of N strings where each string denotes arrival time of the ith train, and one more string denoting current_time, find the minimum wait time for catching the next upcoming train corresponding to the current time. Return 0 if there are no more trains available past current time.

  2. Given a matrix, output the sum of elements whose index is divisible by 3 in spiral order.

  3. You are given a task with Q queries and an integer input limit, where each query can be either of the following:

    • +X: Add value X to the list
    • -X: Remove first occurring X from the list

    Initially, the list should contain zero elements. For each query, perform the given operation and find the total number of pairs in the list such that their absolute difference is equal to limit. Return the list of output for all Q queries.

Candidate's Approach

No approach provided.

Interviewer's Feedback

No feedback provided.