Sunday, April 26, 2020

C++ Challenge #5 | Bank Management System part (1/3) (Interview Preparat...







here is the part 1/3 code





// Bank Management system

// requirements

// 1) Deposite money

// 2) withdraw money

// 3) balance

// 4) transfer

// 5) program exit



#include <iostream>

using namespace std;

int totalamount = 500;



int deposite_amount;

int withdraw_amount;

int transfer_amount;

void deposite(){

cout << "Enter the amount you want to deposite" <<endl;

cin >> deposite_amount;

totalamount += deposite_amount;

cout << "payment has been deposite" <<endl;

}

void withdraw(){

cout << "Enter the amount you want to withdraw" <<endl;

cin >> withdraw_amount;

totalamount -= withdraw_amount;

cout << "payment has been withdrawn";

}

void balance(){

cout << "total amount " << totalamount;

}

void transfer(){

cout << "Enter the amount you want to transfer" <<endl;

cin >> transfer_amount;

totalamount -= transfer_amount;

cout << "payment has been transfered";

}

main(){









}


No comments:

Post a Comment