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 

Code constraints 1

Step by Step Solution

3.44 Rating (151 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

include using namespace stdint main int tc cin tc while... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Accounting Questions!