September 5, 2024
Agoda Interview Experience (Staff Fullstack Developer) — August 2024
How I applied, interview journey, post-interview process and preparation tips.

By Karan Kumar
5 min read
Applied -> Interviewed -> Got Rejected 🤓
Introduction
Being part of the Agoda interview journey is both exciting and challenging. Having recently navigated the process, I wanted to share my experience to assist others in their Agoda interviews.
How I Applied
I applied through the LinkedIn job postings of Agoda, and within a few weeks, the recruiter reached out to me via email. She shared useful articles detailing the role of a Staff Fullstack Developer.
Round 1: DSA/Algorithm
The first round focused on the Data Structures and Algorithms, lasting 60 minutes.
It began with a brief introduction and an overview of my current role and tech stack. This was followed by two DSA problems of medium level.
You can choose to use any language you are comfortable with to solve these problems, and the main idea is to think out loud. The second problem was quite challenging for me, but the interviewer was really helpful in making me understand the exact requirements no matter how many times I asked.
So, I went with C++ and here are my solutions to the questions asked:
Step-by-Step Breakdown:
- Initialize variables:
maxlength = 0: To store the result.char_map: Empty map to store characters and their most recent positions.start = 0: The start of the window.
- Iterate over the string with a loop (using
endas the current character index):
- For each character at position
end, check if it has already appeared in the current window.
- Check for repeating characters:
- If the character
current_charhas been seen before (exists inchar_map), it means there's a repeat. - Move the
startpointer to the right of the previous occurrence ofcurrent_charto remove the repeated character from the current window.
- Update the map with the current position of
current_char. - Update
maxlength:
- After processing each character, calculate the current window's length:
end - start + 1. - Compare it with
maxlengthand update if the current window is longer.
Visualizing Sliding Window:
start end
↓ ↓
a b c a b c b b
↑_____↑ start end
↓ ↓
a b c a b c b b
↑_____↑- As the loop iterates, the
startpointer moves to exclude repeated characters, while theendpointer keeps moving forward. - The window adjusts dynamically, and the longest valid substring is tracked.
Final Output: The function returns, which is the length of the longest substring without repeating characters.
This is a sliding window technique using a hash map to track character positions and dynamically adjust the window to ensure no repeating characters in any valid substring.
Step-by-Step Breakdown:
- Create Hash Map (unordered_map):
- Define an unordered map
cpc(cumulative position count), where: — Key: Cumulative width (distance from the left edge of the wall to the right end of a brick). — Value: The count of how many rows end at this cumulative width.
- Iterate Over Each Row of the Wall:
- For each row in the wall, calculate the cumulative width (sum of brick widths) for each brick except the last one (we don't count the very edge of the wall, as the line won't go beyond that).
- For each cumulative width
cw, increment its count in the mapcpc.
- Find the Maximum Frequency (Most Common Cumulative Width):
- Iterate through the
cpcmap and find the cumulative width where the most rows end (i.e., the most common gap between bricks). - This helps identify where the vertical line should be drawn to cross the fewest bricks.
- Calculate the Result:
- The result is the total number of rows (
wall.size()) minus the maximum frequency (mf), which gives the minimum number of bricks that the vertical line will cross.
Visualizing the Vertical Line:
Here is the wall with the line drawn at the cumulative width 3:
start end
↓ ↓
| 1 | 2 | 2 |
| 3 | 1 | 1 |
| 2 | 3 |
↑ Line at width = 3 start end
↓ ↓
| 1 | 2 | 2 |
| 3 | 1 | 1 |
| 2 | 3 |
↑ Line at width = 3- The vertical line is drawn at cumulative width
3, where 2 rows end (minimizing the number of bricks crossed). - The line crosses only 1 brick in total, which is the optimal solution.
Final Output:
The function returns 1, meaning the fewest number of bricks the line will cross is 1.
This approach efficiently finds the optimal position to draw a vertical line by tracking the cumulative widths where gaps between bricks occur and choosing the gap that maximizes the number of rows without crossing bricks.
Preparation tip: Solidify your understanding of core algorithms and data structures, particularly topics such as arrays, strings, linked lists, trees, graphs and dynamic programming.
Round 2: System Design (HLD — Got Rejected)
I was given a complex scenario(Figma/Excalidraw-like application architecture) and was asked to provide HLD with a scalable and efficient solution to address the requirements.
For 60 minutes, I proposed high-level designs.
Main topics of discussion: How and Why WebSockets will be used, why Canvas is used instead of SVG, What can we do to handle large-scale document editing for 5k-10k concurrent users, and how Various protocols can be utilized for this purpose.
This round required a comprehensive understanding of system design principles, and the interviewer challenged my design choices.
NOTE: Not providing the solution; mine was not qualified, but sharing resources that I went through post-interview.
Round 3,4: System Design (LLD) and Hiring Manager (HM)
If you clear Round 2, these will be the next rounds.
Interview Preparation Tips
Here are some tips to help you put your best foot forward before facing interviews:
- Review Core Concepts: Brush up on fundamental computer science concepts such as data structures, algorithms, object-oriented programming, and database management.
- Technical Knowledge: Demonstrate proficiency in programming languages and technologies trending in the industry. Knowledge of cloud, caching, queue mechanisms, microservices, and design principles would keep you ahead of most of us.
- Know Your Resume: Know what is written there. Expect many questions about your past experiences and tech stack.
- Projects and Portfolio: Discuss personal or academic projects, emphasizing the challenges faced and solutions implemented.
- Problem Solving: Practice coding challenges and algorithmic problems to enhance your problem-solving abilities and coding skills.
- Behavioural Questions: Anticipate and prepare for behavioural questions and your real experiences with teamwork, handling challenges, and your approach to software engineering situations.
- Company Research: Familiarize yourself with the company's mission, values, and recent projects. Align your skills with the company's objectives.
- Ask Questions: Prepare thoughtful questions about the company culture, team dynamics, and growth opportunities to demonstrate genuine interest in the role.
Let's Connect
Reach out to me for mentorship, resume reviews, interview preparation guides, or a roadmap tailored to your career goals. Connect with me for:
- 1:1 Mentorship Sessions
- Resume Reviews and Enhancements
- Interview Preparation Guides
- Data Structures and Algorithms Guidance
- High-Level Design (HLD) and Low-Level Design (LLD) Insights
- Coding Practice Strategies
- Roadmap to Crack Product-Based Companies
In conclusion, the Agoda interview process is tough and time-consuming, but with thorough preparation and a strategic approach, you can get selected. Good luck to all future candidates!
To stay up to date on my content:
Subscribe here so you never skip a beat from the author's updates!
I am excited to announce the launch of our much-awaited technical publication:
Feel free to let me know in responses, or read the Write For Us story if you'd like to join the community.
For more discussion on this topic, you can always connect with me 1:1.