Question: C PROGRAMMING LOCAL AND GLOBAL VARIABLES LAB EXERCISES INTRODUCTION Go through the lecture notes on functions I and II to familiarize yourself with the concepts

C PROGRAMMING LOCAL AND GLOBAL VARIABLES LAB EXERCISES INTRODUCTION Go through the lecture notes on functions I and II to familiarize yourself with the concepts Practice 1. Copy the code above into your editor and study it. 2. Declare a global float variable called balance and initialize it. The value should represent the user's bank account balance 3. Write appropriate function declarations and definitions for the following functions: a. authenticate - to check whether the user's pin number is correct b. requestAmount - ask user to enter the amount of money for a transaction c. deposit-credit user's account balance d. withdraw - debit user's account balance e. transfer-request for recipient's account number and debit sender's account 4. Convert the tries local variable to a static local variable and observe the difference in the code 5. Identify the local and global variables in the code 6. Start and Menu are called goto labels. Observe their roles in the code. What is their role in the program? 7. Modify the program to end after the user enters the wrong pin 4
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
