I recently appeared for an online assessment test focused on Data Structures and Algorithms (DSA) hosted on the HackerRank platform. The test had a total duration of 110 minutes, during which I was required to solve two challenging DSA problems. Each question was designed to assess my problem-solving skills, understanding of core DSA concepts, and ability to implement efficient algorithms under time constraints. The problems required careful analysis, code optimization, and rigorous testing.
Interview questions [1]
Question 1
1st problem
Problem Statement
You are given an array sequenceData of n positive integers. You may perform the following operation any number of times (including zero):
Choose a prefix of length s (1 ≤ s ≤ n) that contains no zeros.
Subtract 1 from each element in that prefix.
After performing operations in any order, determine the maximum number of zeros that can appear in the array.
2nd problem
You are given two strings:
sourceString: the original string in which you need to search.
pattern: a simplified regex-like pattern that contains exactly one asterisk '*'. The '*' can match any (possibly empty) substring of sourceString.
Your task is to find the length of the longest possible substring in sourceString that:
Starts with the prefix before the '*' in pattern, and
Ends with the suffix after the '*' in pattern,
And the prefix and suffix do not overlap unless the '*' can represent the in-between part (or nothing at all).
If no such match exists, return -1.
I applied through an employee referral. The process took 3 months. I interviewed at Amazon (Seattle, WA) in Jun 2025
Interview
There were 3 rounds, each 1 hour and were done on the same day. Each round had two parts; the first 25–30 minutes focused on behavioral questions, and the remaining 25–30 minutes were dedicated to a DSA question. Two of the DSA questions were LeetCode medium-level and tagged with Amazon, while one was a hard-level question. The interviewers were friendly and helpful, never intimidating or arrogant.
Interview questions [1]
Question 1
All the regular behavioral questions were asked, for example, “How do you take criticism?” and “How do you identify the root cause of a problem?” They weren’t particularly tough, but each question had multiple follow-ups and could be quite grilling. The LeetCode questions were recently Amazon-tagged and were only minor variations of those.
I applied through a recruiter. The process took 1 week. I interviewed at Amazon (Jordan, MN) in Jun 2025
Interview
The interview process started with an online assessment that included debugging questions and algorithmic challenges under strict time constraints. The problems were medium to hard level on LeetCode, and understanding the question quickly was critical. I felt the time pressure was intense and made it difficult to think clearly. The questions tested core data structures like hash maps, stacks, and arrays. There was no live interview after the OA. I received a rejection email a few days later. Overall, the process was challenging but fair. Make sure to prepare well and practice mock tests with time limits.
Interview questions [1]
Question 1
One of the coding problems asked to find the number of subarrays with exactly K distinct integers.