miles - } else { b = 100 * 0.25; c = a - 100; e = c * 0.15;...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#include <iostream> using namespace std; void main () { float a, b, c, d, e; cout << "Enter the number of miles." << endl; cin >> a; if (a<=100) { b = a * 0.25; cout << "The Total price owed is $" << b << endl;
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: } else { b = 100 * 0.25; c = a - 100; e = c * 0.15; d = e + b; cout &lt;&lt; &quot;The Total price owed is $&quot; &lt;&lt; d &lt;&lt; endl; } }...
View Full Document

This note was uploaded on 07/27/2011 for the course COL 201 taught by Professor Magtibay during the Winter '10 term at De La Salle Lipa.

Ask a homework question - tutors are online