Use if-else to execute different blocks based on conditions.
In an e-commerce app, if-else statements can determine if a customer qualifies for a discount. For example, if a customer's total purchase is above $100, a discount may apply. This allows the app to execute specific logic for eligible customers.