C++ Assignment to add five functions

Price: $35 USD

Question description

Add five additional functions (services/options you have available when you use the ATM machine or bank with a cashier).

Submit two files: 

a cpp file for the source you wrote

a pdf file of the source you wrote; color in blue or red the five functions you added (this will help me in the grading process).

#include <iostream>
using namespace std;

double transaction;
double currentBalance (5000);

char pickTransaction(void);
void message (void);
void deposit(void);
void withdraw(void);

// This code only perform one transaction. Modify it to give the user opportunity to perform as many operations as she/he desires.
int main()
	cout << " Welcome to Your Bank! \n" << endl;
	char letter = pickTransaction();
	if ((letter == 'D') || (letter == 'd'))
	if ((letter == 'W') || (letter == 'w'))
	if ((letter == 'B') || (letter == 'b'))
	system ("pause");
	return 0;

char pickTransaction()
	char input;
	do {
		cout << "What transaction would you like to perform today? Enter D for Deposit, W for Withdraw, or B to see your Balance \n";	
		cin >> input;
	while ((input != 'B') && (input != 'b') && (input != 'W') && (input != 'w')&& (input != 'D')&& (input != 'd'));
	return input;

void message (void)
	cout << " your new balance is: $" << currentBalance << endl;

void deposit(void)
	cout << "How much do you want to deposit? \n";
	cin >> transaction;
	currentBalance = currentBalance + transaction;

void withdraw(void)
	cout << "How much do you want to withdraw? \n";
	cin >> transaction;
	if (currentBalance <=0)
	{cout << " Your balance is low; transaction cannot be performed. \n";}
	{currentBalance = currentBalance - transaction;}

Tutor Answer

(Top Tutor) Daniel C.
School: Cornell University
Studypool has helped 1,244,100 students
Ask your homework questions. Receive quality answers!

Type your question here (or upload an image)

1823 tutors are online

Brown University

1271 Tutors

California Institute of Technology

2131 Tutors

Carnegie Mellon University

982 Tutors

Columbia University

1256 Tutors

Dartmouth University

2113 Tutors

Emory University

2279 Tutors

Harvard University

599 Tutors

Massachusetts Institute of Technology

2319 Tutors

New York University

1645 Tutors

Notre Dam University

1911 Tutors

Oklahoma University

2122 Tutors

Pennsylvania State University

932 Tutors

Princeton University

1211 Tutors

Stanford University

983 Tutors

University of California

1282 Tutors

Oxford University

123 Tutors

Yale University

2325 Tutors