Back To C++ Flow of Control Index


price is taken as input from user, if price is entered above 1000, discount is calculated as 10% of price else 5% of price
to calculate 10% discount, price is multiplied with 0.1
to calculate 5% discount, price is multiplied with 0.05