Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Put your names at the beginning of your program Collaborative work and submission in pairs only are allowed Any program written and completed by
Put your names at the beginning of your program Collaborative work and submission in pairs only are allowed Any program written and completed by an Al ChatBot (ChatGPT) will be immediately rejected Write a description of your program and what you have used in 2-4 lines Take a screenshot of your program OR copy and paste it into a docs/word document, and submit it along with the description * Program 1: Bank account transaction program A basic bank account program that allows a user to deposit or withdraw money. The program greets the user, shows their current balance, and prompts them to choose between depositing or withdrawing. Users enter the desired amount, and the program updates the balance. If an invalid input is provided, the program resets the transaction process. The program runs continuously, allowing multiple transactions until the user stops it manually. Steps: Ask the user if they want to 1 deposit or 2 withdraw (use if statements) If the user inputs something other than 1 or 2, the loop will reset If the user selects deposit, the program will add the value to the bank variable If the user selects withdraw, the program will deduct the value from the bank variable Whenever the user inputs an invalid number (like a negative, or withdrawal is bigger than the bank variable amount, the loop will do nothing and reset) Since it's an infinite loop, the loop should never stop asking for a deposit or withdrawal * Program 2: User sign-in with multiple passwords chances An account sign-in program that asks a user to enter their username and password. The program provides the user with 5 attempts to enter the correct password. If the correct password is entered, the user gains access. If an incorrect password is entered, the remaining attempts are displayed, and a password hint is provided when only one attempt is left. If all attempts are used, the account is locked, and the user can no longer access it. Steps: Whatever the username is given, it will be accepted. The user can input their password with 5 chances only. If the user inputs the password correctly, they will be admitted to continue the program. (Else), every time the user inputs a wrong password, it will deduct 1 chance. (use deductive while loop or for loop) Once the chances are done, the program will stop allowing for more password inputs and stop the program. (hint: use comparison operator (Ex: a=="password") and nest statements) > Console Shell x + bank account transaction program Enter your name: Shrek Welcome to your bank account Shrek You currently have 15000 $ in your account Would you like to desposit or withdraw? Enter 1 to desposit, or 2 to withdraw: 1 how much would you like to desposit?:5000 Success! Total amount of 5000 has been added to your account. your new total = 20000 $ Would you like to desposit or withdraw? Enter 1 to desposit, or 2 to withdraw: 2 How much would you like to withdraw?: 10000 Success! Total amount of 10000 has been dedcuted from your account. your new total = 10000 $ Would you like to desposit or withdraw? Enter 1 to desposit, or 2 to withdraw: > Console X Shell x + A program to sign-in into account and check your password. Input your username = Dummy258 Welcome, Dummy258 Input your password = juk8762s Incorrect password, tries left = 5 Input your password = miony 72s! Incorrect password, tries left = 4 Input your password = nobad82 Incorrect password, tries left = 3 Input your password = abcd Correct password, welcome to the world The program is complete
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started