Interview Experience: PayU | SDE-1 | Round 1
Summary
I interviewed for an SDE-1 role at PayU (Round 1) where the focus was on problem solving and data structures; I solved two questions using binary search and a greedy approach.
Full Experience
The round was primarily focused on Problem Solving and Data Structures. The interviewers were helpful and encouraged me to think out loud, focusing on both the logic and time complexity.
Interview date: 13th May 2026
The Problems:
- Frequency of an element in a Sorted Array Problem: Given a sorted array, count the occurrences of a target element k. Example: arr = [3, 5, 5, 5, 6, 9, 10], k = 5 → Output: 3
My Approach: While a linear search works in O(n), the "sorted" property is a hint to use Binary Search. I implemented two binary searches to find the first and last occurrence of k, resulting in an optimized O(log n) solution.
- Minimum Jumps to Reach the End Problem: You are given an array where each element represents the maximum jump length from that position. Find the minimum number of jumps to reach the end. Example: jump = [2, 1, 1, 3, 4] → Output: 3
My Approach: This is a classic Greedy/DP problem (similar to Jump Game II). I used a Greedy BFS-like approach to track the farthest reachable point at each step, ensuring the solution runs in O(n) time complexity.
Interview Questions (2)
Frequency of an Element in a Sorted Array
Given a sorted array, count the occurrences of a target element k.
Example: arr = [3, 5, 5, 5, 6, 9, 10], k = 5 → Output: 3
Minimum Jumps to Reach the End
You are given an array where each element represents the maximum jump length from that position. Find the minimum number of jumps to reach the end.
Example: jump = [2, 1, 1, 3, 4] → Output: 3