#include using namespace std; int main() { const double COST_PER_PAGE = 0.02; const double BASE_COST = 0.50; int volumes = 1; int pages = 0; int ppv = 0; double cost = 0; cout << "Number of pages in the book: "; cin >> pages; if (pages <= 0) { cerr << "Books have pages...exiting."; return 0; } cost = BASE_COST + (COST_PER_PAGE * pages); ppv = pages; if (pages > 800) { } else if (pages > 550) cost += 1.75; else if (pages > 300) cost += 1.00; cout.setf(ios::fixed); cout.setf(ios::showpoint); cout.precision(2); cout << "The cost of the book will be: $" << cost << endl; cout << "Volumes: " << volumes << endl; cout << "Page per Volume: " << ppv << endl; system("pause"); return 0; }