Help with assignment please!

Hi
This is my first post.

I need help with my assignment which I have to do in visual studio using C++.
It has to handed in next week. So I`ll be truly greatful if anyone can help.

Write a program that reads in a distance in miles, then calculates and displays the corresponding shipping cost. Each shipment incurs a fixed cost of £50 and the price per mile is calculated according to the rules below
•Each of the first 100 miles (inclusive) cost £5.50
•Over 100 miles and up to 500 miles (inclusive): £4.00 per mile.
•Over 500 miles: £2.50 per mile.

For example, the cost of shipment over a distance of 550.50 miles is £2326.25
(i.e., £50 + (100*5.5) + (400*4.0) + (50.5*2.5)).

If the user enters a negative amount or zero for the distance the program should display an error message.

Thanks
start with your code, see where you stuck
Topic archived. No new replies allowed.