Freshworks SSE Interview (Virtual)

freshworks logo
freshworks
Software EngineerVirtual2.2 yearsOngoing
September 26, 202510 reads

Summary

I interviewed for a Software Engineer role at Freshworks, which involved three rounds: Data Structures & Algorithms, System Design, and a Managerial round. I am currently awaiting the final results.

Full Experience

Round 1: Data Structures & Algorithms

This round was taken by a lead software engineer and focused mainly on DSA. I was asked about my current work and to provide an example for meta-information of a report, as my team deals with reporting.

  • Given a set of intervals representing meeting start and end times, I had to determine if a person could attend all meetings. I was then asked to refactor my code, specifically to decrease the number of lines by moving my custom comparator into lambda expressions.
  • I was asked to find the maximum subarray sum.

Round 2: System Design

A week later, I had the System Design round with another lead software engineer. This round included some questions based on my current team and how I spend a day at my company.

  • I was asked to explain how Authentication and Authorization work.
  • The interviewer asked about the difference between PATCH and PUT HTTP methods.
  • We discussed sharding: what it is, its usefulness, the 'celebrity problem,' and how to handle changes in the number of servers.
  • I had to differentiate between partitioning and sharding.
  • The discussion moved to indexing: how it helps in query optimization and its internal workings.
  • I was asked if I review PRs and how I provide review comments to colleagues.
  • The interviewer presented a scenario of facing a 504 gateway timeout and asked about potential causes, troubleshooting steps, and solutions.
  • I was asked to design a high-level architecture for a WhatsApp-like chat system. I wasn't thoroughly prepared for system design, but I talked about websockets and message queues for notifications. He then asked me to look deeper into how websockets work.

Round 3: Managerial Round

Another week later, I had the managerial round with a staff engineer. We discussed query optimizations, why Redshift was chosen over PostgreSQL in my current team's architecture, and a shard migration tool I had worked on.

  • The core question was to design a web scraper given a start URL and a level 'n' until which URLs need to be scraped, returning a list of all scraped URLs. I initially proposed a simple HLD where requests are processed synchronously by hitting URLs, downloading data, and processing recursively. However, the interviewer was not satisfied, pointing out its limitations for very large depths (e.g., billions). I then suggested using a Message Queue with client requests as producers and worker threads as subscribers to process results asynchronously. For responses, I thought of using a storage like Amazon S3, providing pre-signed URLs to the client's email. When asked about status updates without email, I suggested a UI logs page to show 'Queued / IN_PROGRESS / SUCCESS / FAILED' statuses. He then presented a follow-up: what if a worker thread processing 1 million requests crashes after processing 0.5 million? I explained that we could run NFRs to determine a threshold level for crashes, use that threshold to set breakpoints or checkpoints to store partial results, and maintain meta-information about the request. If a failure occurs, we would resume processing from the last successful checkpoint.

Interview Questions (11)

Q1
Meeting Rooms I
Data Structures & AlgorithmsMedium

Given a list of meeting time intervals [start, end], determine if a person could attend all meetings. Each meeting is a closed interval [start, end].

Q2
Maximum Subarray Sum
Data Structures & AlgorithmsEasy

Given an integer array nums, find the contiguous subarray (containing at least one number) which has the largest sum and return its sum.

Q3
Authentication and Authorization Mechanisms
System Design

Explain the fundamental concepts and mechanisms of authentication and authorization in a system.

Q4
HTTP PATCH vs. PUT
System Design

Differentiate between HTTP PATCH and PUT methods, including their use cases and idempotency.

Q5
Database Sharding and Consistency Hashing
System Design

Explain what sharding is, its utility, and discuss the 'celebrity problem' in the context of sharding. How do you handle changes in the number of servers (e.g., using consistent hashing)?

Q6
Partitioning vs. Sharding
System Design

Explain the concept of partitioning and how it differs from sharding in database design.

Q7
Database Indexing
System Design

Describe what database indexing is, how it aids in query optimization, and its internal working mechanisms.

Q8
Code Review Best Practices
Behavioral

Describe your experience with code reviews and how you provide constructive feedback to colleagues.

Q9
Troubleshooting 504 Gateway Timeout
System Design

Discuss potential causes of a 504 Gateway Timeout error, how to diagnose the issue, and common solutions.

Q10
High-Level Design for WhatsApp-like Chat System
System DesignHard

Design a high-level architecture for a real-time chat system similar to WhatsApp.

Q11
Design a Distributed Web Scraper
System DesignHard

Design a web scraper that takes a start URL and a depth n, and returns a list of URLs scrapped up to that level. Discuss handling large depths (e.g., billions of levels), ensuring fault tolerance, and providing status updates to users without email.

Preparation Tips

My learning from this experience was that I wasn't adequately prepared for system design interviews, as I hadn't gone through any system design resources. The interviewer implied that the interview itself wasn't inherently tough, and I would have performed better with proper system design preparation.

Discussion (0)

Share your thoughts and ask questions

Join the Discussion

Sign in with Google to share your thoughts and ask questions

No comments yet

Be the first to share your thoughts and start the discussion!