Contribute OA questions
OAHelper
CompaniesProblemsTopicsInterview Experiences
Explore
G

Google

SDE

Interview Date

31-08-2026

Result

Selected

Difficulty

Easy

Rounds

01

Drive Type

Off-Campus

Interview Date

31-08-2026

Result

Selected

Difficulty

Easy

Rounds

01

Drive Type

Off-Campus

Topics asked

DSA

Detailed experience

PART 1: ALGORITHMIC PROBLEM - SWEEP LINE & INTERVAL DYNAMIC PROGRAMMING BASE PROBLEM You are building a resource allocation engine for a cloud compute cluster. You are given a list of compute jobs, where each job is represented by a `start_time` and an `end_time`. Task: Design an algorithm to find the minimum number of independent server nodes required to execute all jobs such that no two overlapping jobs share the same server. How do you implement a Sweep Line algorithm using a sorted array of chronological events (or a Min-Heap) to solve this in strictly O(N log N) time, and why does a greedy approach work here? FOLLOW-UP 1 The business model changes from minimizing servers to maximizing profit. You now only have a single server, and each job comes with an associated `profit`. You must select a non-overlapping subset of jobs that yields the maximum total profit. The standard Sweep Line or greedy approach completely fails here. How do you design an algorithm combining Sorting, Binary Search (e.g., `std::upper_bound`), and 1D Dynamic Programming to find the maximum profit in strictly O(N log N) time? FOLLOW-UP 2 The single server is upgraded to a continuous rolling 24-hour edge node. The jobs are now represented on a circular time axis (meaning a job can start at 11:00 PM and end at 2:00 AM, wrapping around the midnight boundary). A standard linear DP array fails because the start and end of the array are logically connected, creating circular dependencies in the DP state transitions. How do you modify your algorithm to break the circularity—by conditionally excluding overlapping boundary jobs or running the linear DP exactly twice—to solve the circular maximum weight independent set problem in O(N log N) time? ------------------------------------------------ PART 2: SYSTEM DESIGN - DISTRIBUTED KEY-VALUE STORE (DYNAMODB / CASSANDRA) BASE PROBLEM You are designing a globally distributed, highly available Key-Value store (similar to Amazon DynamoDB or Apache Cassandra). The system must handle millions of reads and writes per second with sub-10ms latency. Design the high-level architecture, focusing on how data is partitioned across the cluster and how read/write operations are routed to the correct node. FOLLOW-UP 1 As the database scales, you frequently need to add new server nodes to the cluster or remove hardware that has caught fire. If you partition data using a simple modulo hash (e.g., `hash(key) % N`), adding a single node will change the modulo divisor, requiring you to move nearly 100% of the data across the network to rebalance. How do you implement Consistent Hashing with Virtual Nodes to ensure that adding or removing a server only requires moving `1/N` of the data, guaranteeing uniform load distribution? FOLLOW-UP 2 To achieve ultimate high availability, the system is designed as a masterless (leaderless) architecture. During a severe network partition between data centers, two different users update the exact same key simultaneously on two different nodes. Both nodes accept the write. How do you design the system to handle this split-brain scenario? Explain how Tunable Consistency (Quorum reads/writes) and Vector Clocks are used to detect the conflict and allow the client application to resolve the divergent data versions on the next read. ------------------------------------------------ PART 3: AI / LLM DISCUSSION QUESTIONS In the context of memory-constrained LLM training, what is "Activation Checkpointing" (or Gradient Checkpointing), and how does it trade a 33% increase in computational overhead (FLOPs) for a massive reduction in the GPU VRAM required during the backward pass? How do grammar-constrained decoding frameworks (like llama.cpp's GBNF grammar rules) manipulate the output logits at inference time? Why is this mechanism mathematically guaranteed to produce valid JSON or code, unlike standard prompting techniques? Explain the "Length Generalization" problem in standard Transformer architectures. Why does a model trained on sequences of exactly 4,096 tokens completely collapse into gibberish when asked to generate token 4,097, and how do positional embedding modifications (like YaRN) address this? What is the fundamental difference between standard Multi-Layer Perceptron (MLP) routing in a dense transformer and the routing mechanism in a Sparse Mixture of Experts (MoE) architecture? Specifically, how is the Top-K gating function calculated and applied to the hidden states?

Posted on - 24 Sept 2026
Company OAsAll ProblemsTopicsCompany InsightsOA CalendarInterview ExperiencesPremium
OAHelper

Built by students, for students - practice company-specific OAs, DSA sheets, and real interview experiences to land your dream role.

© 2026 OAHelper.in·Terms·Privacy·Refunds·Trust & Safety·Contact·
Ready to crack your next OA?

Practice company-specific questions trusted by thousands of students across India.

Start PracticingGo Premium
OA Practice·DSA·Placements

Disclaimer: OAHelper is an independent educational platform. We (oahelper.in) do not own the images or questions shown. Content is uploaded by users.