Contribute OA questions
OAHelper
CompaniesProblemsTopicsInterview Experiences
Explore
M

Microsoft

sde

Interview Date

21-08-2026

Result

Rejected

Difficulty

Medium

Rounds

03

Drive Type

Off-Campus

Interview Date

21-08-2026

Result

Rejected

Difficulty

Medium

Rounds

03

Drive Type

Off-Campus

Topics asked

dsa

Detailed experience

PART 1: ALGORITHMIC PROBLEM - BITWISE TRIE & MAXIMUM XOR BASE PROBLEM You are analyzing network packets with unique integer signatures. Task: Given an array of non-negative integers `nums`, design an algorithm to find the maximum possible bitwise XOR operation of any two numbers in the array. While a brute-force approach checking every pair takes O(N^2) time, how can you represent the integers as 32-bit binary strings and insert them into a Prefix Tree (Trie) to find the maximum XOR pair in strictly O(N) time? FOLLOW-UP 1 The problem expands to handle continuous range queries. You are given an array of `N` elements and `Q` queries. Each query is in the form `(L, R, X)`, asking for the maximum XOR of the integer `X` with any element in the subarray from index `L` to `R` inclusive. Since you cannot build a new Trie for every query without hitting a Time Limit Exceeded (TLE) error, how do you optimize the Trie structure (e.g., storing the minimum or maximum array index in the subtree nodes) and process the queries offline to solve this in O((N + Q) log M) time? FOLLOW-UP 2 The network signatures are now updated dynamically. You need to support appending new numbers to the array and querying historical versions of the array (e.g., "Find the max XOR with X using only the array as it existed at version `V`"). Rebuilding the Trie for each version will cause an immediate Out Of Memory (OOM) crash. How do you implement a Persistent Trie (similar to a Persistent Segment Tree) where consecutive versions safely share immutable nodes, ensuring that both appending a number and querying a historical version take strictly O(1) space and time relative to the number of bits? ------------------------------------------------ PART 2: SYSTEM DESIGN - DISTRIBUTED PAYMENT GATEWAY BASE PROBLEM You are designing the backend for a global payment gateway (similar to Stripe). The system provides an API for merchants to process credit card transactions. It must ingest the payment request, securely communicate with the external acquiring bank network, and record the outcome. Design the high-level architecture, focusing on fault tolerance and external API integration. FOLLOW-UP 1 Mobile clients frequently experience network drops. A user might initiate a $100 payment, but the connection drops before they receive the confirmation. The client automatically retries the exact same request. How do you design an Idempotency framework using a distributed cache (like Redis) combined with your primary relational database to guarantee the user is never double-charged, even if an application server crashes mid-transaction? FOLLOW-UP 2 Every successful transaction must be recorded in an immutable, double-entry financial ledger (e.g., Debiting the User, Crediting the Merchant). At scale, this monolithic ledger database becomes a write bottleneck and must be sharded. However, a single transaction often involves accounts residing on completely different database shards. How do you maintain strict ACID compliance across these distributed shards without relying on the notoriously slow and blocking Two-Phase Commit (2PC) protocol? (Discuss the Saga Pattern, outbox pattern, or deterministic transaction routing). ------------------------------------------------ PART 3: AI / LLM DISCUSSION QUESTIONS In a Mixture of Experts (MoE) architecture, how does the distinction between "active parameters" and "total parameters" fundamentally alter the ratio of required GPU VRAM compared to inference compute (FLOPs) when compared to a dense model of the same size? What is QLoRA (Quantized Low-Rank Adaptation), and how does the introduction of the 4-bit NormalFloat (NF4) data type and Double Quantization allow massive foundational models to be fine-tuned on single consumer-grade GPUs without catastrophic accuracy loss? How do high-performance LLM serving engines implement "Chunked Prefill" (or Chunked Context), and how does this scheduling technique balance the GPU utilization between processing a massive new incoming prompt and generating the next tokens for active, concurrent users? Explain the "Reversal Curse" observed in Large Language Models (e.g., a model trained on "A is B" completely fails to deduce that "B is A"). What does this phenomenon reveal about the fundamental limitations of the standard autoregressive, next-token prediction training objective?

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.