Bird
Raised Fist0

In a restaurant management system, which class is best suited to handle customer orders?

easy🧠 Conceptual Q1 of Q15
LLD - Design — Food Delivery System
In a restaurant management system, which class is best suited to handle customer orders?
ACustomer class
BMenu class
CRestaurant class
DOrder class
Step-by-Step Solution
Solution:
  1. Step 1: Understand the role of each class

    The Menu class holds food items, the Restaurant class manages overall operations, and the Customer class represents the customer.
  2. Step 2: Identify the class responsible for orders

    The Order class is designed to handle customer orders, including items selected and quantities.
  3. Final Answer:

    Order class -> Option D
  4. Quick Check:

    Order handling = Order class [OK]
Quick Trick: Orders belong to the Order class, not Menu or Restaurant [OK]
Common Mistakes:
MISTAKES
  • Confusing Menu with Order
  • Assigning orders to Restaurant class
  • Using Customer class for orders

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More LLD Quizzes