ATM Project: A C++ Implementation of a Basic Banking System, Schemes and Mind Maps of Computer science

A c++ project that simulates a basic banking system. It covers fundamental concepts of software engineering, data structures, and object-oriented programming. The project includes user account management, transaction processing, input validation, and user interface implementation. A detailed explanation of the code structure, including classes, functions, and data structures used. It also highlights challenges and considerations encountered during development, such as data structure design, error handling, and input validation. Valuable for students learning c++ and object-oriented programming principles.

Typology: Schemes and Mind Maps

2024/2025

Uploaded on 02/23/2025

axel-reich
axel-reich 🇺🇸

4 documents

1 / 12

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
ATM Project
Gary Silvers, Gerald Logan, Axel Reich
Introduction:
The banking sector is witnessing a significant transformation driven by
technological advancements. In line with this trend, the development of a basic
banking application using C++ offers an insightful exploration into the
fundamentals of software engineering, data structures, and object-oriented
programming principles. This project aims to create a simple yet functional
banking system capable of account management, balance inquiries, deposits,
withdrawals, and fund transfers.
Project Overview:
The project revolves around a C++ program designed to emulate the functionalities
of a bank. It utilizes object-oriented programming concepts to organize the code
into manageable classes and structures. The primary components of the project
include user account management, transaction processing, input validation, and
user interface implementation.
User Account Management:
User accounts are managed using a custom-defined struct named userInfo. This
struct encapsulates essential user information such as PIN, checking balance, and
savings balance. User accounts are stored in an unordered map data structure
(userMap), where the username serves as the key and the userInfo struct serves as
the value. The createAccount method allows users to create new accounts with the
provided credentials.
Transaction Processing:
pf3
pf4
pf5
pf8
pf9
pfa

Partial preview of the text

Download ATM Project: A C++ Implementation of a Basic Banking System and more Schemes and Mind Maps Computer science in PDF only on Docsity!

ATM Project Gary Silvers, Gerald Logan, Axel Reich Introduction: The banking sector is witnessing a significant transformation driven by technological advancements. In line with this trend, the development of a basic banking application using C++ offers an insightful exploration into the fundamentals of software engineering, data structures, and object-oriented programming principles. This project aims to create a simple yet functional banking system capable of account management, balance inquiries, deposits, withdrawals, and fund transfers. Project Overview: The project revolves around a C++ program designed to emulate the functionalities of a bank. It utilizes object-oriented programming concepts to organize the code into manageable classes and structures. The primary components of the project include user account management, transaction processing, input validation, and user interface implementation. User Account Management: User accounts are managed using a custom-defined struct named userInfo. This struct encapsulates essential user information such as PIN, checking balance, and savings balance. User accounts are stored in an unordered map data structure (userMap), where the username serves as the key and the userInfo struct serves as the value. The createAccount method allows users to create new accounts with the provided credentials. Transaction Processing:

The banking application supports various transactional operations, including deposits, withdrawals, and fund transfers. Methods such as checkDep, savDep, checkWithdraw, savWithdraw, toCheckTrans, and toSavTrans facilitate these operations. Input validation is implemented to ensure that transactions are processed accurately and securely. For instance, withdrawal transactions verify the availability of sufficient funds before processing. User Interface Implementation: The user interface is implemented through the runMenu function, which presents a menu of banking operations to the user. Users interact with the program by selecting options from the menu and providing input as necessary. The user interface is designed to be intuitive and user-friendly, facilitating seamless navigation and interaction with the banking application. Challenges and Considerations: Throughout the development process, several challenges and considerations were encountered. These include: Implementation of Data Structures: Designing an efficient data structure for storing user accounts and managing transactions required careful consideration of factors such as performance, scalability, and ease of implementation. The use of an unordered map proved to be suitable for this purpose due to its fast lookup and insertion capabilities. Error Handling and Input Validation: Ensuring robust error handling and input validation mechanisms were essential for preventing unauthorized access, data corruption, and erroneous transactions. Implementing comprehensive input validation routines helped mitigate potential security vulnerabilities and safeguard the integrity of banking operations.

  • printMenu: Print the menu options for the user.
  1. Member Function runMenu:
  • Takes a username as input and displays a menu of banking operations.
  • Based on user input, it calls corresponding member functions to perform the selected operation.
  • It continues to display the menu until the user chooses to exit.
  1. main() Function:
  • Creates an instance of the Accounts class named user.
  • Initializes some sample user accounts using the createAccount method.
  • Displays a welcome message and prompts the user to choose between logging in, opening a new account, or exiting.
  • Based on the user's choice, it either logs in an existing user, opens a new account, or exits the program.
  1. Input Validation:
  • The code lacks robust input validation. For instance, it does not handle cases where the user inputs non-numeric values or negative amounts for deposits/withdrawals.
  1. Recursion:
  • The main() function calls itself recursively when the user enters incorrect credentials. This can lead to potential issues such as stack overflow if many incorrect attempts are made.
  1. Program Flow:
  • The program flow can be improved by breaking down the main logic into smaller functions and handling input validation more effectively.
  1. Exiting the Program:
    • The exit function call in the main() function is incorrect. It should be exit(0) or return 0 to properly exit the program. Overall, while the code provides basic functionality for a banking application, it could be enhanced with better input validation, improved program flow, and a more robust approach to error handling. When interacting with it in the terminal: Welcome to Baker Bank!
  2. Login
  3. Open new account

pedro $1000 was deposited to checking. $1000 was deposited to savings. Welcome, pedro! What would you like to do today?

  1. Check Balances
  2. Make a Checking Withdrawl
  3. Make a Checking Deposit
  4. Make a Savings Withdrawl
  5. Make a Savings Deposit
  6. Transfer from Checking to Savings
  7. Transfer from savings to checking
  8. Exit. 2134
  9. Check Balances
  10. Make a Checking Withdrawl
  11. Make a Checking Deposit
  12. Make a Savings Withdrawl
  13. Make a Savings Deposit
  14. Transfer from Checking to Savings
  15. Transfer from savings to checking
  16. Exit. 1

Current balance in Checking is: $1000. Current balance in Savings is: $1000.

  1. Check Balances
  2. Make a Checking Withdrawl
  3. Make a Checking Deposit
  4. Make a Savings Withdrawl
  5. Make a Savings Deposit
  6. Transfer from Checking to Savings
  7. Transfer from savings to checking
  8. Exit. 2 Enter withdraw amount: 10000 Withdrawing 10000. Insufficient funds, cannot withdraw. Welcome, pedro! What would you like to do today?

Enter transfer amount: 342 Transfer successful. pedro Checking: 658. Savings: 1342.

  1. Check Balances
  2. Make a Checking Withdrawl
  3. Make a Checking Deposit
  4. Make a Savings Withdrawl
  5. Make a Savings Deposit
  6. Transfer from Checking to Savings
  7. Transfer from savings to checking
  8. Exit. 5 Enter deposit amount: 3821 Depositing $3821. pedro Checking: 658.

Savings: 5163.

  1. Check Balances
  2. Make a Checking Withdrawl
  3. Make a Checking Deposit
  4. Make a Savings Withdrawl
  5. Make a Savings Deposit
  6. Transfer from Checking to Savings
  7. Transfer from savings to checking
  8. Exit. 4 Enter withdraw amount: 10993 Withdrawing 10993. Insufficient funds, cannot withdraw. Welcome, pedro! What would you like to do today?
  9. Check Balances
  10. Make a Checking Withdrawl
  11. Make a Checking Deposit