Question
Single file programming questions. While purchasing certain items, a discount of 10% is offered if the quantity purchased is more than 1000. If the quantity
Single file programming questions.
While purchasing certain items, a discount of 10% is offered if the quantity purchased is more than 1000. If the quantity and price per item are input, write a program to calculate the total
expenses.
Input format.
The first line contains an integer T, total number of test cases. Then follow T lines, each line contains integers quantity and price.
Output format
For each test case, output the total expenses while purchasing items, in a new
line.
Code constraints
• 1≤T≤1000
• 1 quantity, e <= 100000
Sample test cases is given in pic..
Code constraints 1
Step by Step Solution
3.44 Rating (151 Votes )
There are 3 Steps involved in it
Step: 1
include using namespace stdint main int tc cin tc while...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get StartedRecommended Textbook for
Managing Supply Chain and Operations An Integrative Approach
Authors: Thomas Foster, Scott E. Sampson, Cynthia Wallin, Scott W Webb
1st edition
132832402, 978-0132832403
Students also viewed these Accounting questions
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
Question
Answered: 1 week ago
View Answer in SolutionInn App