Sample report
A real AI mock interview report, unedited
This is the report from one real 50-minute CureBugs round: a low-level design interview for a Flipkart software engineer role, taken by a real candidate on 17 November 2026. It is exactly what every candidate gets after every round: the scores, the quotes behind them, where points were lost and what to practise next.
Only two things are missing from the real thing: the audio playback, which stays private, and the buttons for rating and flagging.
49
out of 100
Software engineer · Flipkart
LLD: Design discussion · 50 min · spoken · problem: Coupons and discounts
Your mock interview for the Software Engineer role at Flipkart resulted in an overall score of 49 out of 100, meaning your next step is to keep preparing, and with targeted practice, you will absolutely get there. You demonstrated a solid foundation in your low-level design, particularly through your excellent initial separation of concerns between coupon metadata and discount calculation. You also did a great job correctly identifying that rules must be evaluated before applying any discounts. The most important thing for you to work on next is remaining collaborative and adaptable when new requirements challenge your initial architecture, rather than becoming defensive or pushing core business logic like coupon stacking onto external services. By focusing your future preparation on gracefully embracing design changes and building flexible interfaces for features like item-based discounts, you will be well on your way to a successful interview.
- 12scores, each with its reason
- 21quotes from the candidate, timestamped
- 16questions, most of them follow-ups
How the interview went
A score is only as good as the interview behind it. These are six moments from the transcript, word for word. The candidate's side is speech-to-text, so it keeps the slips of talking out loud.
1 · at 1:48
It sets the scope, like a real panel
Candidate: “Can you clearly state more of the requirement features? As of now, coupon and discount engine for a checkout system seems like, let's say if I'm at the, for example, payment page, there I can look at the available coupons and based on the available coupons, I…”
Interviewer: “You mentioned payment method discounts, but let's keep payments entirely out of scope for today. For the platform level discounts you brought up, a coupon gives either a percentage or a flat discount on the whole cart or on a specific category, and we only allow one coupon per order at first. What else would you like to know about the coupon rules before we start designing the classes?”
The candidate brought up payment-method discounts. The interviewer took them out of scope and gave the actual coupon rules, so the round stayed on one problem.
2 · at 9:49
It asks why, not just what
Candidate: “Okay, so talking about domain classes, okay. Okay, so few of the classes which I'm thinking as of now is I would just say let's say that cart is what is giving me the order. So I would not bother to go into the cart, I would just focus on my own classes. Okay,…”
Interviewer: “You mentioned that a coupon is a type of discount, but is that an 'is-a' relationship, or does a coupon have a discount? Walk me through that choice. Also, you wanted to keep the cart out of your classes, but how will your rules evaluate things like a minimum cart value without it?”
Instead of accepting "a coupon is a type of discount", it asks whether that is an is-a or a has-a relationship, and spots that the rules can't check a minimum cart value without the cart.
3 · at 17:01
It reads the code in the editor
Candidate: “Okay, I'm writing. Let's say we have a bigger class which is coupon and we would have, I'm just writing pseudo code so don't expect it to work, but let's say we have string of name, we would have a string of validity start and string of validity end. Instead…”
Interviewer: “I see you have the abstract Discount class and the concrete percentage and flat implementations set up in the editor. To see how these objects interact, walk me through exactly what happens in your CouponService when a user applies a coupon like SAVE20 to a 1,200 rupee cart.”
It saw the abstract Discount class and its two subclasses the candidate had just written, then asked them to trace a real case: SAVE20 on a ₹1,200 cart.
4 · at 20:17
It pushes back on a weak answer
Candidate: “We can add more information like the rule's name as well and the what message to be shown depending on constant message and store those inside the rules and once the rules version failed pass on that message exception to the for the class who is inheriting and…”
Interviewer: “You mentioned throwing an exception with the message when a rule fails. Since a coupon condition not being met is normal business logic, using exceptions for control flow is often considered an anti-pattern. How could you return this failure reason to the caller without relying on exceptions?”
The candidate said a failed coupon rule would throw an exception. A senior interviewer would challenge that, and so did this one.
5 · at 22:32
It adds a new requirement midway
Candidate: “Sorry, I did not get it. What do you mean by signature changes? I mean, of course, there would be changes. I mean, there's only success that we are returning. There is only failure that we are returning. At few points, I am returning only true. There this…”
Interviewer: “Returning a dedicated result object with a status and a message is a clean way to handle that. Let's introduce a new requirement: marketing now wants to allow stacking up to two coupons per order, applied in a specific sequence. How would you adjust your design to handle multiple coupons and enforce the order they are applied in?”
Real low-level design rounds do this to see whether the design bends or breaks. Here it was coupon stacking. A minute later came buy two, get one free.
6 · at 25:18
It holds the candidate to their own design
Candidate: “I mean the return type won't be amount final amount. The return type would be the item category that is what I would return. So once that type of coupon is applied, the discount type won't be flat or percentage, it would be the category type of discount. And I…”
Interviewer: “You mentioned adding a new discount type that returns the free items instead of an amount. But right now, your discount interface requires the calculate method to return a double, which the service just subtracts from the total. How would you change that interface so the engine can handle both monetary deductions and free items?”
The candidate's calculate method returns a number, so it can't express free items. The interviewer pointed at that exact line.
The scorecard: LLD: Design discussion
Each dimension shows its score, what that level means on the rubric, the candidate's own words behind it, and how to do better. The lowest here were handling the new requirement, patterns and principles and explaining trade-offs, at 40 each.
Clarifying requirements
50/100weight 1Turns the short prompt into clear use cases, actors and scope by asking.
Scored 2.5 of 5: between "Asks one or two vague questions." and "Covers the main use cases."
What a 5 needs: Sharp scoping that shapes the design, with what's left out said.
The candidate asked some relevant questions to clarify the scope, such as distinguishing between platform and payment discounts, and asked about the user experience of showing coupons.
- 1:38“One would be of course the platform level, the second would depend on the payment method basis.”
- 4:18“whenever a user lands on order page, that's where we would like to show them the number of coupons for them, right?”
- 4:18“No, I think I don't have any other question given we have majority of the things out of scope.”
Where points were lost: You covered the main use cases but missed clarifying the core constraints of the coupon rules themselves (like stacking, priority, or specific conditions) before jumping into the design.
How to improve: Next time, ask specific questions about the domain rules: 'Can coupons be stacked?', 'Are there priority rules?', or 'What specific conditions must a coupon have?'. This will help you shape a more robust design from the start.
Classes and relationships
60/100weight 1.3The right objects with clear responsibilities and relationships.
Scored 3 of 5: A workable set of classes and relationships.
What a 5 needs: An elegant model that anticipates change.
The candidate proposed a workable set of classes (Coupon, Discount, Rule, RulesEvaluationManager) and correctly identified that a Coupon has a Discount.
- 9:37“coupon as a bigger class which has many of the sub objects. And the second thing which I would have is discount as a class and rules evaluation is I would say a bigger class”
- 11:13“a discount is a type of how that coupon will be used. Let's say the discount would be percentage or flat.”
- 9:37“So I would not bother to go into the cart, I would just focus on my own classes.”
Where points were lost: While you had a workable set of classes, the responsibilities were slightly blurred, and the design did not anticipate changes well, such as handling different types of discount returns.
How to improve: Ensure that your core domain models are completely decoupled from external services. Think about how the
Discountclass interacts with theCartand whether theCouponshould compose bothDiscountandRuledirectly.Interfaces and methods
60/100weight 1Key methods and interfaces, with variation behind abstractions.
Scored 3 of 5: Reasonable methods on the right classes.
What a 5 needs: Precise contracts, easy to extend and test.
The candidate wrote reasonable pseudo-code with abstract classes for Discount and Rule, and concrete implementations for percentage and flat discounts.
- 22:22“Sorry, I did not get it. What do you mean by signature changes?”
Where points were lost: Your interfaces were reasonable but lacked the flexibility to handle variation without breaking contracts, as seen when the return type of
calculateDiscount(double) couldn't support free items.How to improve: Design interfaces that return domain objects (like a
DiscountResultorCartModification) rather than primitives likedouble. This allows you to extend the behavior (e.g., returning free items) without changing the method signature.Handling the new requirement
40/100weight 1.1Shows how the design takes the new requirement without a rewrite.
Scored 2 of 5: Needs a large rewrite.
What a 5 needs: Takes it by extension alone, as the design anticipated it.
The candidate struggled to adapt the design to new requirements. For stacking, they relied on the client to make sequential calls. For buy-x-get-y, they admitted the interface would need to entirely change and asked to end the interview.
- 23:36“there is not much logic that I should handle here. It's what the card service will return me appropriate total amount and the next call.”
- 26:07“I mean, things entirely change depending on how the PR. I mean, see, if you have given me the requirement type of three items, then of course my boolean, double, int, and all parameters changes.”
- 23:36“So there is not much logic that I should handle here. It's what the card service will return me appropriate total amount and the next call.”
Where points were lost: Your design required a large rewrite to handle the new requirements. You pushed the responsibility of stacking to the client rather than handling it in the engine, and your discount interface was too rigid to support non-monetary discounts.
How to improve: When asked about stacking, introduce a priority field on the Coupon and sort them in the engine before applying. For buy-x-get-y, abstract the return type of the discount calculation to a generic result object that can hold either a price deduction or a list of free items.
Patterns and principles
40/100weight 0.8Uses design patterns and SOLID where they fit, and can say why; forced patterns count against.
Scored 2 of 5: Names patterns without fitting them.
What a 5 needs: Precise, well-justified use, with the trade-offs named.
The candidate named patterns like Singleton and Factory but did not explain how they fit into the current design or justify their use.
- 26:51“I mean the design pattern is of course inheritance is there. There's singleton method, a few of the factory pattern that I can see.”
Where points were lost: You named patterns without demonstrating how they applied to your specific design, which came across as forcing buzzwords rather than applying principles naturally.
How to improve: Instead of just listing patterns, explain exactly where they live in your code. For example, point out that your
Discounthierarchy uses the Strategy pattern, or that evaluating a list ofRuleobjects is an application of the Specification pattern.Edge cases and errors
50/100weight 0.7Thinks about failure paths, invalid states and limits in the design.
Scored 2.5 of 5: between "Mentions errors only when asked." and "Covers the main error cases."
What a 5 needs: Anticipates failures and limits before being asked.
The candidate only addressed error handling when prompted, initially suggesting exceptions for business logic flow before correcting to a structured response.
- 20:10“once the rules version failed pass on that message exception to the for the class who is inheriting”
- 21:08“this would be just 200 request and rule evaluation not met, which is returned to the order service.”
- 20:10“We can add more information like the rule's name as well and the what message to be shown depending on constant message and store those inside the rules and once the rules version failed pass on that message exception to the for the class who is inheriting”
Where points were lost: You only thought about failure paths when explicitly asked, and your initial approach of using exceptions for normal business logic (rule failures) is an anti-pattern.
How to improve: Anticipate failure states proactively. When designing an evaluation engine, immediately consider how to communicate *why* an evaluation failed back to the user, using structured result objects rather than exceptions.
Explaining trade-offs
40/100weight 0.9Explains why each choice, the alternatives and their costs, and answers cross-questions clearly, using the whiteboard or editor.
Scored 2 of 5: Explains what, not why.
What a 5 needs: Leads the discussion, naming trade-offs before being asked.
The candidate explained what their design did but struggled to explain why, and became defensive when pressed on how the design might bend or break.
- 26:51“By bind, what do you mean exactly?”
- 28:10“Any other thing which I am thinking of I mean it's generic enough so not able to think apart from payments.”
Where points were lost: You struggled to explain the reasoning behind your choices and could not identify the structural weaknesses in your design when asked where it might bend.
How to improve: Practice critiquing your own designs. Be ready to say, 'This choice makes X easier, but makes Y harder.' When asked where a design might break, look at your interfaces and identify what assumptions they make (e.g., 'My interface assumes all discounts are monetary').
Since this interview, the low-level design rubric has gained an eighth dimension, concurrency: finding shared state and races, and fixing them safely.
Spoken delivery
Scored on voice rounds to help you sound as good as you are. These don't change the round score.
Clarity
60/100not counted in the round scoreEasy to follow when speaking.
Scored 3 of 5: Mostly clear.
What a 5 needs: Very clear and well articulated.
The candidate's explanations were generally understandable, though sometimes slightly convoluted when discussing class relationships.
Where points were lost: Your explanations of how classes interacted were sometimes hard to follow without prompting.
How to improve: Use concrete examples earlier when explaining abstract concepts to make your thought process clearer.
Conciseness
60/100not counted in the round scoreGets to the point.
Scored 3 of 5: Sometimes long.
What a 5 needs: Crisp and economical.
The candidate kept answers relatively brief but occasionally rambled when unsure of the answer.
Where points were lost: You sometimes talked around the problem when you weren't sure of the answer, rather than getting straight to the point.
How to improve: If you are unsure, it is better to pause, think, and give a direct answer rather than thinking out loud in a circular way.
Pace
100/100measured, not judgedSpeaking pace (words per minute).
Scored 5 of 5: Ideal, varied pace.
About 123 words per minute.
Filler words
80/100measured, not judgedUse of um, uh, like, basically.
Scored 4 of 5: Few fillers.
What a 5 needs: Almost none.
1.4 filler words per 100 words.
Confidence
40/100not counted in the round scoreSounds assured without overclaiming.
Scored 2 of 5: Hesitant.
What a 5 needs: Calm and assured.
The candidate lost confidence significantly when their design was challenged, ultimately asking to end the interview early.
Where points were lost: You became visibly flustered and defensive when a new requirement broke your design, asking to end the interview rather than working through the problem.
How to improve: Treat new requirements that break your design as a collaborative problem-solving exercise, not a failure. It is normal for designs to need refactoring during an interview.
Strengths
- Good initial separation of concerns between the Coupon metadata and the Discount calculation.“coupon has let's say name inside it and let's say validity... But a discount is a type of how that coupon will be used.” · 11:13
- Correctly identified that rules should be evaluated before applying a discount.“we have something known as calculate discount which would say if our rule is satisfied otherwise return minimum of the discount amount” · 19:19
Weak spots
- Became defensive and tried to end the interview early when faced with a requirement that broke their design.“can we move on to the final one minute because I just want to end the interview.” · 26:07
- Pushed business logic for coupon stacking onto external services instead of handling sequencing inside the discount engine.“So there is not much logic that I should handle here. It's what the card service will return me appropriate total amount and the next call.” · 23:36
- Became defensive and dismissed interface adaptability when prompted to support item-based discounts.“I mean, see, if you have given me the requirement type of three items, then of course my boolean, double, int, and all parameters changes. I mean, that goes without saying. So can we move on to the…” · 26:07
Better answers
For the questions that cost the most points: what the candidate said, and what a strong answer sounds like.
23:36
How would you adjust your design to handle multiple coupons and enforce the order they are applied in?
They said: “Given the current design, I don't see much of a issue. We have card, we have coupons and everything. Once a particular, let's say coupon is applied, I can return the total amount, final amount that I have and I can show the next price and when the customer clicks on second coupon applied, then my total amount received onto the second call is what gets changed. So there is not much logic that I sho…”
A strong answer: I would add a priority integer to the Coupon class. The CouponEngine would accept a list of coupon codes, fetch them, sort them by priority, and then apply them sequentially to the cart, passing the updated cart state to the next coupon's evaluation.
26:07
How would you change that interface so the engine can handle both monetary deductions and free items?
They said: “I mean the gist of that, there won't be a return type of double. I mean, things entirely change depending on how the PR. I mean, see, if you have given me the requirement type of three items, then of course my boolean, double, int, and all parameters changes. I mean, that goes without saying. So can we move on to the final one minute because I just want to end the interview.”
A strong answer: I would change the return type of calculateDiscount from double to a new DiscountResult class. This class could contain a double discountAmount and a List<Item> freeItems. The CouponService would then inspect this result and apply both the monetary deduction and add the free items to the cart.
Reference design
A Coupon combines a list of Conditions (minimum cart value, first order, validity dates, category) with a discount strategy (percentage with a cap, flat, buy-x-get-y). The CouponEngine checks each condition in turn (the Specification pattern) and returns the first failure as the reason, then applies the discount to the cart or the matching items, never below zero. Stacking applies coupons in a set priority. New coupon types are new conditions or strategies, never edits to the engine. A limited coupon uses an atomic counter of redemptions.
What the candidate wrote in the editor (at 16:46)
1. apply coupon XYZ
2. remove the coupon applied coupon
classes
cart ->
---
coupon
Discount
RulesEvaluationManager
Rules
Coupon -> Discount -> [ Rules ], [RulesEvaluationManager]
Class Cart {
string cartId;
List<CartItem> items;
double totalAmount;
double getTotalAmount();
double getCategoryAmount(string category);
}
Class Coupon {
string couponCode;
DateTime validityStart;
DateTime validityEnd;
bool isActive;
Discount discount;
bool isValid();
}
Abstract Class Discount {
List<Rule> rules;
RulesEvaluationManager rulesManager;
virtual double calculateDiscount(Cart cart) = 0;
bool areRulesSatisfied(Cart cart);
}
Class PercentageDiscount extends Discount {
double percentage;
double maxDiscountAmount;
double calculateDiscount(Cart cart) {
if (!areRulesSatisfied(cart))
return 0;
double discount = cart.getTotalAmount()
* percentage / 100;
return min(discount, maxDiscountAmount);
}
}
Class FlatDiscount extends Discount {
double discountAmount;
double calculateDiscount(Cart cart) {
if (!areRulesSatisfied(cart))
return 0;
return min(discountAmount, cart.getTotalAmount());
}
}
Abstract Class Rule {
virtual bool evaluate(Cart cart) = 0;
}
Class MinimumCartValueRule extends Rule {
double minimumAmount;
bool evaluate(Cart cart) {
return cart.getTotalAmount() >= minimumAmount;
}
}
Class CategoryRule extends Rule {
string category;
bool evaluate(Cart cart) {
return cart.getCategoryAmount(category) > 0;
}
}
Class RulesEvaluationManager {
bool evaluateAll(List<Rule> rules, Cart cart) {
for (Rule rule : rules) {
if (!rule.evaluate(cart))
return false;
}
return true;
}
}
Class CouponService {
CouponRepository couponRepository;
ApplyCouponResponse applyCoupon(
string couponCode,
Cart cart
) {
// 1. Fetch coupon
Coupon coupon = couponRepository.getCoupon(couponCode);
if (coupon == NULL)
return FAILURE("Invalid coupon");
// 2. Check coupon validity
if (!coupon.isValid())
return FAILURE("Coupon expired or inactive");
// 3. Calculate discount
double discount = coupon.discount.calculateDiscount(cart);
if (discount <= 0)
return FAILURE("Coupon conditions not satisfied");
// 4. Apply discount
cart.setAppliedCoupon(coupon);
cart.setFinalAmount(
cart.getTotalAmount() - discount
);
return SUCCESS(discount, cart.getFinalAmount());
}
RemoveCouponResponse removeCoupon(Cart cart) {
if (cart.getAppliedCoupon() == NULL)
return FAILURE("No coupon applied");
cart.removeAppliedCoupon();
cart.setFinalAmount(cart.getTotalAmount());
return SUCCESS();
}
}The action plan
Read
How to learn low-level design
Your LLD: Design discussion round scored 49 out of 100, weakest on clarifying requirements, classes and relationships, interfaces and methods, handling the new…
Read
Low-level design: an LRU cache
Matched to the topics you found hardest.
Next mock
Next mock: LLD: Design discussion
Practise your weakest round (LLD: Design discussion) again in a week.
How the scoring works
A fixed rubric for every round type
This round was scored on 7 dimensions. Each is scored 1 to 5 against written descriptions of what every level looks like, and shown out of 100 (the 1 to 5 score × 20). Each row above shows what a 5 would have needed.
Two graders, scoring separately
Two independent AI graders score the round without seeing each other's work. When they disagree by more than a point on any dimension, a third pass breaks the tie.
Every quote is checked
Each score has to point at what the candidate actually said. A quote that isn't in the transcript is thrown out before the report is written, so the evidence below is word for word.
A weighted score, and a verdict set by code
The round score is the weighted average of the dimensions (weights shown on each row). The verdict comes from fixed thresholds, not from the AI: Strong from 82, Ready from 70, Almost there from 55, otherwise Keep preparing. In a multi-round interview, rounds count by length, and any round under 40 caps the verdict at Almost there.
Spoken delivery, scored separately
Voice rounds also get clarity, conciseness and confidence scores. Pace and filler words are measured from the audio and transcript, not judged. These are shown to help you improve and don't change the round score.
You can challenge any score
Every line on a real report has a flag button. A reviewer reads each flag, and flags are used to tighten the rubric.
The full transcript
All 31 lines, as recorded. Times are minutes:seconds from the start of the round.
Show the transcript
- 0:06Interviewer: Hello, I am Ira, and today we have about fifty minutes for a low level design discussion. You have a brief prompt about designing a coupon and discount engine for a checkout system, so what would you like to clarify before you start?
- 1:38Candidate: Can you clearly state more of the requirement features? As of now, coupon and discount engine for a checkout system seems like, let's say if I'm at the, for example, payment page, there I can look at the available coupons and based on the available coupons, I can apply one of the best coupon which it suggested or the coupon which I would like to use. And on the basis of that, the price decreases and henceforward I can use any payment option. Let's say depend if we discuss about the coupons, then there would be two types of discount. One would be of course the platform level, the second would depend on the payment method basis. I'm including the platform level discount as a generic term which would have the item level coupons or let's say even a permanent sale or let's say few days sale of the coupon. That's what I'm thinking of. Please correct me if that's what you mean.
- 1:48Interviewer: You mentioned payment method discounts, but let's keep payments entirely out of scope for today. For the platform level discounts you brought up, a coupon gives either a percentage or a flat discount on the whole cart or on a specific category, and we only allow one coupon per order at first. What else would you like to know about the coupon rules before we start designing the classes?
- 4:18Candidate: Yeah, yeah, yeah, that helps. So, let's say, yeah, if you remove the payment level discount, then we have only the platform level discounts. And in the platform level discounts, we can divide it into two. First is the percentage, second is the flat. Of course, each of the percentage and flat discounts depend on cart and categories. I will classify that as a evaluation engine. And of course, for right now, we can only allow one coupon per order. That's completely fine because we are only thinking of coupon based thing. Okay. In terms of requirement, I think if we remove order and the payment out of scope, and let's say there's 1000 rupees order and we are applying 100 rupees discount, this means that 900 would be the total order value. If I have to classify any of the question, then it would be something as minimum discount should be of one rupee that I am expecting or I think that's also not required. So, I just remove that. I'm just thinking if there are any other things to let's say we have coupons, we have rule evaluations, we have daily basis. No, I think I don't have any other question given we have majority of the things out of scope. One thing I do want to clarify, whenever a user lands on order page, that's where we would like to show them the number of coupons for them, right? They don't have to specifically click on the coupon thing before showing the coupons. It should be first visible in the order page.
- 4:26Interviewer: You asked about showing coupons on the order page: for now, let's assume the user just enters a coupon code at checkout, and the engine either applies it or tells them why it failed. Since you don't have any other questions on the rules, what are the main objects in this system, and how do they relate? You can use the whiteboard if it helps.
- 6:50Candidate: Yeah, I can use relay, I mean close to whatever there is the classes and method, I would like to use that text interface for my better clarification, but yeah, for this seems fine. Let's say depending on this what I would like to see is first let's go from API or let's say use case perspective. The first use case is give me all available coupons based on, and this based on is a trigger terms. It means user, category, time, let's say platform, level or current evaluation and so many more things that can happen, so I will just keep it open. Second thing is give me all like apart from give me all available coupons, second thing would be apply coupon, let's say XYZ and this would either give us a success or for failure. And the third thing which I am thinking is of course remove the coupon, that is basically just the field list of the apply or maybe the success. Remove the applied coupon. If there is anything which I am thinking of? No, I don't think. Do I need anything else? But this is a major use case. These three are the major use case based on which I can proceed further with the diagram.
- 6:57Interviewer: You've listed the main use cases, but remember we are just focusing on the user entering a specific code, so we can skip fetching all available coupons for now. To make that "apply coupon" flow work, what domain classes do we need to represent the cart, the discount rules, and the coupon itself?
- 9:37Candidate: Okay, so talking about domain classes, okay. Okay, so few of the classes which I'm thinking as of now is I would just say let's say that cart is what is giving me the order. So I would not bother to go into the cart, I would just focus on my own classes. Okay, let's say if my own class starts from here and it will end in here. Okay, so if I will talk about only my classes, that would be first thing that we would we have is coupon as a bigger class which has many of the sub objects. And the second thing which I would have is discount as a class and rules evaluation is I would say a bigger class and there would be I would say rules evaluation manager and there would be rules. Each rules has its own evaluation method and all which rules evaluation manages and for okay and each of the discounts has its own rule. So if let's say I have to show it in some diagram form then it would be like a coupon is a type of a discount. This discount is also a class and there's a subclass of rules and each and this discount contains some of the let's say rules and to figuring out which rules to call we would have a rules evaluation manager in here.
- 9:49Interviewer: You mentioned that a coupon is a type of discount, but is that an 'is-a' relationship, or does a coupon have a discount? Walk me through that choice. Also, you wanted to keep the cart out of your classes, but how will your rules evaluate things like a minimum cart value without it?
- 11:13Candidate: Yeah, so basically I was talking about cart as something which is provided to me which I am not maintaining. Cart is of course a class that would be provided to me as an input. So first thing that regarding second thing is relationship between coupon and a discount. So coupon is a let's say a string. I mean coupon has let's say name inside it and let's say validity as well and few other things metadata I would like to call it. But a discount is a type of how that coupon will be used. Let's say the discount would be percentage or flat. So it's a kind of a coupon can be a type of particular discount and there is a different type of discounts which are available let's flat or the percentage.
- 11:19Interviewer: Got it, so the cart is passed in as an input, and a coupon holds the metadata while the discount handles the calculation. Let's see this in code: could you write out these key classes and their main methods in the editor? Pseudocode is fine.
- 16:52Candidate: Okay, I'm writing. Let's say we have a bigger class which is coupon and we would have, I'm just writing pseudo code so don't expect it to work, but let's say we have string of name, we would have a string of validity start and string of validity end. Instead of string I can go with better, let's say date time. I'm not focusing on exact format to be precise. Validity end and I would have a discount. So this is the type of class that I would like to have. If there would be a separate class of let's say discount, okay, I would like it as type and the type would be let's say percentage. I think I'm just thinking is percentage and is flat. So these type of words. So I think I can keep a separate something called enumerator and which would have flat discount and percentage discount and enumerator let's say discount type. So I would have discount type and something known as discount type. Just to keep things simple. There are other things that is possible inside a discount. So I'm not going into that. Let's say minimum or maximum can be defined here, but I think it's still property of the coupon. Discount would be right now this much, but of course we can add more things as it comes. Let's say percentage and evaluation and then flat discount evaluation. These are the things that I can do as well. But of course I can have class of rules and I've added the card class as well, coupon class as well. I'm just thinking of a discount class. This would be abstract and depends on the implementation. And this would be percentage discount, flat discount or maybe how many type of discount that we want. We can do that. We can add flat discounts if that's what we mean. We can have rule that's also abstract because evaluate is the minimum thing, major thing. And we have too many types of rules and category rule and whatever that we would like to have. And we would like to have rules evaluation manager. Then we need coupon service. This is where the main business logic lives. So that's it.
- 17:01Interviewer: I see you have the abstract Discount class and the concrete percentage and flat implementations set up in the editor. To see how these objects interact, walk me through exactly what happens in your CouponService when a user applies a coupon like SAVE20 to a 1,200 rupee cart.
- 19:19Candidate: Okay, then I mean I would say let's say save 20 the type of flat discount just assuming initially for a 1200 rupees card. Card information is already provided to me, so I'm just expecting card ID some of the random string. There's a list of items that I don't care of, but the total amount is 1200. Get total amount gets 1200 get category amount gives the total category amount, but that's irrelevant. The main thing is the event is coupon coupon code is save 20. I'm expecting all the coupon codes to be a unique and start and end time I would say lies in our range. So just skip to that is active is true. That's why the coupon is working. I would say discount is another class. We'll come back to it, but is valid is what gives evaluation of these coupon rules validity. Okay, is valid is I don't think I have implemented it, but that's what evaluates whether this particular coupon is true or not, but let's say it would be simple evaluation only, so that's fine. Coming back to the discount, that's what is inside the coupon. We have a list of rules and we have rules manager, we have calculate discount are rules satisfied or not. Let's say since we're talking about flat discount and we have discount as a type of abstract class. So we have something known as calculate discount which would say if our rule is satisfied otherwise return minimum of the discount amount and the card total amount. Just a value which will give 20. That's how our rule evaluation worked. Rule manager told make the total evaluation and inside the coupon service we will check if the apply coupon and that's how we go back to the initial our card to discount.
- 19:28Interviewer: You walked through checking if the rules are satisfied before calculating the flat discount. Right now, your rule evaluation just returns a boolean, so the service returns a generic "conditions not satisfied" message. If a coupon requires both a minimum cart value and a specific category, how would you change your design to tell the user exactly which rule failed?
- 20:10Candidate: We can add more information like the rule's name as well and the what message to be shown depending on constant message and store those inside the rules and once the rules version failed pass on that message exception to the for the class who is inheriting and that's how we can show the minimum cart value in the specific category.
- 20:17Interviewer: You mentioned throwing an exception with the message when a rule fails. Since a coupon condition not being met is normal business logic, using exceptions for control flow is often considered an anti-pattern. How could you return this failure reason to the caller without relying on exceptions?
- 21:08Candidate: I mean, I think as incorrectly said exception, this would be just 200 request and rule evaluation not met, which is returned to the order service. And once inside the rule evaluation not met, there would be a proper contextual defined way to say that this is the reason why the rule was not met and this is the user message which you can show. And that's the future discussion of the order service, whether they want to show that and whether they want to control that business logic on their end or not.
- 21:18Interviewer: Got it, returning a structured response instead of an exception makes sense. How exactly would you change the method signature of your evaluate method in the Rule class to pass that contextual message back up to the CouponService?
- 22:22Candidate: Sorry, I did not get it. What do you mean by signature changes? I mean, of course, there would be changes. I mean, there's only success that we are returning. There is only failure that we are returning. At few points, I am returning only true. There this would be, I mean, a structured, let's say, structured response which would have its own class and its success true as a inherited, not inherited, I mean, that success failure as a field of post class, which is methods, and it has its own details. So I would return those classes instead of this just failure or the true.
- 22:32Interviewer: Returning a dedicated result object with a status and a message is a clean way to handle that. Let's introduce a new requirement: marketing now wants to allow stacking up to two coupons per order, applied in a specific sequence. How would you adjust your design to handle multiple coupons and enforce the order they are applied in?
- 23:36Candidate: Given the current design, I don't see much of a issue. We have card, we have coupons and everything. Once a particular, let's say coupon is applied, I can return the total amount, final amount that I have and I can show the next price and when the customer clicks on second coupon applied, then my total amount received onto the second call is what gets changed. So there is not much logic that I should handle here. It's what the card service will return me appropriate total amount and the next call.
- 23:48Interviewer: If the engine receives both coupons at once, it would need to handle that priority sorting internally rather than relying on the cart service to make sequential calls. Let's look at a new requirement: marketing now wants to run buy two get one free offers on specific categories. How would you add this new type of promotion into your existing discount classes?
- 25:09Candidate: I mean the return type won't be amount final amount. The return type would be the item category that is what I would return. So once that type of coupon is applied, the discount type won't be flat or percentage, it would be the category type of discount. And I would return a category and then how many categories are freely available is what gets returned instead of total final amount and the final amount type of thing. So that's not a amount based discount, that's a category based discount and our design handles already discount via percentage or flat, there will be separate type of discount there. So not much of issue.
- 25:18Interviewer: You mentioned adding a new discount type that returns the free items instead of an amount. But right now, your discount interface requires the calculate method to return a double, which the service just subtracts from the total. How would you change that interface so the engine can handle both monetary deductions and free items?
- 26:07Candidate: I mean the gist of that, there won't be a return type of double. I mean, things entirely change depending on how the PR. I mean, see, if you have given me the requirement type of three items, then of course my boolean, double, int, and all parameters changes. I mean, that goes without saying. So can we move on to the final one minute because I just want to end the interview.
- 26:15Interviewer: You're right that the return types would need a broader structure to handle both cases, so let's move on to the final section as you suggested. Looking at your overall design, which design patterns or principles did you lean on, and where would this design bend first?
- 26:51Candidate: I mean the design pattern is of course inheritance is there. There's singleton method, a few of the factory pattern that I can see. Of course, rules and evaluation are there. By bind, what do you mean exactly?
- 26:58Interviewer: By bend, I just mean where the design might start to struggle or need a major rewrite if we keep adding new requirements. You mentioned using the factory pattern and inheritance, so looking at your current structure, which part do you think would be the hardest to maintain as the system grows?
- 28:10Candidate: I think one thing that needs changing is first is of course that we have payment coupons inside it because we need separate calls and what are payment methods are there whatever the type of things. So these are the type of things which I can think of like apart from platform level. There is anything related to the secondary thing which is play payments can break me. Any other thing which I am thinking of I mean it's generic enough so not able to think apart from payments.
- 28:16Interviewer: You're right that bringing in external payment dependencies would complicate things. Looking at the SOLID principles, can you give a concrete example of how your current class structure follows the Open-Closed Principle as we add new rules and discount types?
Get your own report
Pick a company and a round, upload your CV, and the interviewer asks about your own projects. Every new account gets 100 free coins, enough for one full mock interview.
Common questions
Is this a real interview?
Yes. A real candidate, a backend engineer, took this round on 17 November 2026 to practise for a Flipkart software engineer interview. The scores, quotes, transcript and code are exactly what the report stored. Nothing has been edited, including the speech-to-text slips.
Why publish a report with a low score?
Because a report is only useful if it is honest. A 49 with "Keep preparing" shows the scoring is not inflated to make you feel good, and the report says exactly where the points went and how to get them back.
Does every CureBugs round get a report like this?
Yes. Every round of every interview gets one: CV drill-down, technical, HR, managerial, client, DSA, system design, low-level design and AI debugging. Each round type has its own rubric, scored the same way.
I am a fresher preparing for TCS or Infosys. Is it the same for me?
Yes. A TCS or Infosys style interview runs CV, technical and HR rounds instead of low-level design, and each gets the same kind of scorecard: scores with quotes, where you lost points, a better answer and an action plan.
Who can see my report?
Only you. Reports are private. This one is public because the person who took it chose to publish it.
How much does an interview cost?
Every new account gets 100 free coins, enough for one full mock interview, and each round has a fixed price in coins. The pricing page has the current prices; there is no subscription.