Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

in C .. please the output to be exactly as below. It is the promotional season and everybody can buy the second item for half

in C .. please the output to be exactly as below. image text in transcribed
It is the promotional season and everybody can buy the second item for half price. You will be given the amount bought ( nr. of items) and the unit price of n items. Calculate the total price. Input specification: You will be first given an integer (n), then in the following n lines you will be given two integers. Nr of items: which can be only one or two. Unit price of each item: an int. Output specification: Show one floating point number with two-digits precision: the total price

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Essential SQLAlchemy Mapping Python To Databases

Authors: Myers, Jason Myers

2nd Edition

1491916567, 9781491916568

More Books

Students also viewed these Databases questions

Question

6. Is all Internet training the same? Explain.

Answered: 1 week ago