diff options
| author | WilliamBishopCST116 <[email protected]> | 2022-11-28 12:23:12 -0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-11-28 12:23:12 -0800 |
| commit | 263fc44578143f9198249da1f41da5851c30b482 (patch) | |
| tree | f83813793ad20b1d2852a2391509b4f12e2b97e6 | |
| parent | Add files via upload (diff) | |
| download | cst116-lab3-williambishopcst116-263fc44578143f9198249da1f41da5851c30b482.tar.xz cst116-lab3-williambishopcst116-263fc44578143f9198249da1f41da5851c30b482.zip | |
Add files via upload
| -rw-r--r-- | CST116-lab3-Submit7-Bishop.cpp | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/CST116-lab3-Submit7-Bishop.cpp b/CST116-lab3-Submit7-Bishop.cpp new file mode 100644 index 0000000..b6ac69f --- /dev/null +++ b/CST116-lab3-Submit7-Bishop.cpp @@ -0,0 +1,50 @@ +// BlankConsoleLab.cpp : This file contains the 'main' function. Program execution begins and ends there. +// + +#include <iostream> +#include <fstream> +#include <string> + +using namespace std; + +using std::cout; +using std::cin; +using std::endl; +int totals(int x) +int main() +{ + ofstream inFile; + inFile.open("smaltext.txt"); + cout << "What is the name of the file we have?"; + ofstream file_("taxilogic.txt"); + inFile.open("taxilogic.txt"); + if (file_.is_open()) { + file_ << "total fare = fare+toll \n"; + file_ << "Cost Per Mile = fare / distance\n"; + file_ << " Toll 1, 2, 3, 4 are: 4, 5, 7, 8. \n"; + file_ << " Fare 1, 2, 3, 4 are: 80, 15, 12, 13. \n"; + file_ << " Total Fare 1, 2, 3, 4 are: 84, 20, 19, 21 \n"; + file_ << "Mile rates are 15, 50, 40, 14, \n"; + file_ << " So the Cost per miles are: 5.333,.3,.3, .928 \n "; + in.close(); + } + + double totalfare1[4] = { 84, 15, 12, 13 }; + ofstream file_("totals.txt"); + inFile.open("totals.txt"); + if (file_.is_open()) { + file_ << totalfare1 << endl; + in.close(); + + } + std::cin.get(); + +} +int totals(int x) +{ + double totalfare1[4] = { 84, 15, 12, 13 }; + int = totalpeople; + x = totalpeople; + cout << totalfare1 << endl; + +} |