Autocoder

Flipkart Interview Questions and Answers

Last updated 2026-11-19

Flipkart builds one of India's largest e-commerce platforms, so its interview questions lean on problems that look like the business: catalogue search, carts, inventory that must not oversell, order state machines and sale-day traffic. This page collects practice questions in that style, with worked answers you can adapt in your own words.

The questions are written as practice in the style of the topics the rounds are commonly reported to cover. They are not a record of any particular year's interviews. For the coding side, see Flipkart coding round questions, and for the process itself read how to crack the Flipkart interview.

Typical roundsMachine coding, DSA, hiring manager (commonly reported)
RolesSDE-1, SDE intern
Early careers routeGRiD challenge

Rounds as commonly reported

Candidate reports describe a machine-coding or low-level design round, a data structures round and a hiring-manager round for SDE-1, with an extra system design round for SDE-2 and above. Early-career candidates may come in through Flipkart's GRiD challenge, which is a proctored coding test plus a case study before interviews.

Treat this as a pattern, not a rulebook. Flipkart does not publish its round structure, and it changes by team and level.

Hiring status

Flipkart's own statements about GRiD, which we quote from a source: GRiD 8.0 (2026) registration ran 19 Jun - 12 Jul 2026 for batches 2027-2030, and shortlisted candidates are interviewed for summer internships (3rd year), winter internships and full-time roles (4th year). Source: mycareernet.co/events/flipkart-earlycareers-grid-8-0.

For current news read Flipkart hiring. To apply, use the company's own careers site at flipkartcareers.com. Dates for the next GRiD edition are not announced in any source we have.

How to use these questions

Answer each question aloud first, then compare. For design questions, always state your assumptions and the failure case (oversell, duplicate order, stale price) before you describe the happy path. Interviewers at product companies usually probe the edge you skipped.

Flipkart Interview Questions and Answers: questions with worked answers

  1. 1

    How would you prevent overselling the last unit of a product during a flash sale?

    medium

    The core issue is a race between check and decrement. Do the check and the decrement as one atomic operation: in SQL, UPDATE inventory SET qty = qty - 1 WHERE sku = ? AND qty > 0, and treat zero affected rows as sold out. For very hot SKUs, keep the counter in Redis with an atomic DECR and a Lua script, then reconcile to the database asynchronously. Add a reservation with a TTL at checkout so abandoned carts release stock.

  2. 2

    Design a shopping cart service.

    medium

    Store the cart as a per-user document keyed by user or device id, with SKU, quantity and the price seen when added. Merge the guest cart into the user cart on login. Never trust the cart price at checkout: re-fetch price and stock, and show a change notice if they differ. Cart reads dominate, so cache them and invalidate on write. Expire old carts with a TTL. Mention idempotent add-to-cart calls so a retried request does not double the quantity.

  3. 3

    Why is an idempotency key needed on the place-order API?

    medium

    Mobile networks retry. If a response is lost, the client resends, and without protection you create two orders and charge twice. The client generates a unique key per checkout attempt. The server stores key against the result in a unique-constrained table; a repeat key returns the stored response instead of running again. Keys need an expiry and must be scoped to the user.

  4. 4

    Model an order lifecycle. Which states and which transitions are illegal?

    medium

    A typical chain is CREATED, PAYMENT_PENDING, CONFIRMED, PACKED, SHIPPED, DELIVERED, with CANCELLED, RETURN_REQUESTED and REFUNDED as side branches. Encode allowed transitions in a map from state to set of next states and reject everything else, for example DELIVERED to CANCELLED or SHIPPED to PAYMENT_PENDING. Persist each transition as an event with a timestamp so support can audit it, and make the transition itself a compare-and-set on the current state to avoid two workers moving one order.

  5. 5

    Design search autocomplete for a product catalogue.

    hard

    Use a trie or, at scale, an inverted index with prefix queries (edge n-grams in Elasticsearch). Rank suggestions by a blend of query popularity, recency and personalisation, and precompute the top k per prefix offline. Serve from an in-memory cache with a short TTL, debounce keystrokes on the client, and handle typos with fuzzy matching. State the latency target (tens of milliseconds) because it justifies precomputation.

  6. 6

    Write a thread-safe LRU cache. What do you lock?

    medium

    Combine a hash map with a doubly linked list so get and put are O(1). In Java, extend LinkedHashMap with accessOrder true and override removeEldestEntry, then wrap access in a lock because even a get mutates order. A coarse lock is correct and simple; mention lock striping or a ConcurrentHashMap with per-segment lists only if asked about throughput.

    python
    from collections import OrderedDict
    import threading
    class LRU:
        def __init__(self, cap):
            self.cap, self.d, self.lock = cap, OrderedDict(), threading.Lock()
        def get(self, k):
            with self.lock:
                if k not in self.d: return -1
                self.d.move_to_end(k)
                return self.d[k]
        def put(self, k, v):
            with self.lock:
                self.d[k] = v
                self.d.move_to_end(k)
                if len(self.d) > self.cap: self.d.popitem(last=False)
    java
    import java.util.*;
    class LRU<K, V> {
        private final int cap;
        private final LinkedHashMap<K, V> m;
        LRU(int cap) {
            this.cap = cap;
            this.m = new LinkedHashMap<>(16, 0.75f, true) {
                protected boolean removeEldestEntry(Map.Entry<K, V> e) { return size() > LRU.this.cap; }
            };
        }
        synchronized V get(K k) { return m.get(k); }
        synchronized void put(K k, V v) { m.put(k, v); }
    }
  7. 7

    Difference between HashMap and ConcurrentHashMap, and why not Hashtable?

    easy

    HashMap is not thread-safe and can lose updates or corrupt buckets under concurrent writes. Hashtable locks the whole map on every call, so threads serialise. ConcurrentHashMap allows lock-free reads and fine-grained locking or CAS on writes (per bin in Java 8 and later), and provides atomic helpers such as computeIfAbsent and merge. It also forbids null keys and values because a null return would be ambiguous.

  8. 8

    How do you find the k most frequent search queries in a stream?

    hard

    For exact counts on a bounded vocabulary, keep a hash map of counts and a min-heap of size k: O(n log k). For an unbounded stream, use a Count-Min Sketch for approximate frequencies plus a heap of candidates, or the Misra-Gries algorithm. Partition by hash of the query across workers and merge top-k lists at the end. Say clearly that the sketch overestimates but never underestimates.

  9. 9

    Explain database indexing and when an index hurts.

    medium

    A B-tree index turns a full scan into an O(log n) lookup and supports range queries and ordered reads. For a composite index, column order matters: the index serves queries that use a leftmost prefix. It hurts on write-heavy tables because every insert and update maintains it, on low-cardinality columns such as a boolean, and when it does not cover the query so each row still needs a lookup. Check the plan with EXPLAIN.

  10. 10

    How would you design the product listing page so it stays fast on sale day?

    hard

    Cache aggressively at the CDN and in a service-level cache for catalogue data that changes rarely, and fetch volatile data (price, stock badge) in a separate lightweight call. Paginate with cursors, not offsets. Degrade gracefully: if the recommendation service is slow, render the page without it after a timeout. Use rate limiting and a queue in front of checkout, and load-test before the event.

  11. 11

    Tell me about a time you disagreed with a teammate on a technical decision.

    easy

    Use a short STAR answer. Situation and task in two sentences, then what you did: write down both options with a measurable criterion (latency, effort, risk), try a small prototype or benchmark, and let data decide. Close with the result and what you learned. Avoid blaming; show that you could commit fully to the option that was not yours.

  12. 12

    Why Flipkart, and why this role?

    easy

    Be specific. Mention the scale and the kind of problems (catalogue, supply chain, payments, delivery promise), something real you have used or studied, and how your own project experience connects. Avoid generic lines about being a leader in e-commerce. Finish with what you want to learn in the first year.

  13. 13

    Describe a project where you owned something end to end. What would you change now?

    medium

    Pick a project you can explain to the level of a database table or a failing test. Cover the problem, your design choice and one rejected alternative, one bug that taught you something, and how you knew it worked (tests, metrics). The "what would I change" half is where interviewers judge honesty, so name a real weakness such as missing monitoring or an unindexed query.

Frequently asked questions

Does Flipkart ask machine coding for every SDE-1 candidate?

Candidate reports mention it often, but Flipkart does not publish its process, so it varies by team and year. Prepare for it, since design quality in code is a common differentiator.

How hard are Flipkart DSA questions?

Reports describe medium to hard problems on arrays, trees, graphs and dynamic programming, usually with a request to optimise after a first solution.

Which language should I use?

Use the language you can write correct code in fastest. Java and Python are both common choices; machine-coding rounds reward clean class design in either.

Is there a system design round for freshers?

It is more commonly reported for SDE-2 and above. Freshers should still know caching, indexing and basic API design.

Where do I find current Flipkart openings?

On the company's careers site, and see Flipkart hiring for sourced news.

Sources

Related guides

More in Company Interview Questions

See all in this section