Run Code
|
API
|
Code Wall
|
Users
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
ATM
//gcc 5.4.0 #include <stdio.h> int main(void) { int balance = 5000,deposite,withdraw; int choice,pin,a,accountnumber; printf("Please Enter your accountnumber:\n"); scanf("%d",&accountnumber); printf("Please Enter your pin number:\n"); scanf("%d",&pin); printf("*********WELCOME TO SBI ATM SERVICES*********\n"); printf("1. check balance\n"); printf("2. withdraw\n"); printf("3. Deposite\n"); printf("4. Exite\n"); do{ printf("\nEnter your choice:\n"); scanf("%d",&choice); switch(choice) { case 1: printf("\n your balance in RS : %d",balance); break; case 2: printf("\n Enter the amount to withdraw :"); scanf("%d",&withdraw); balance = balance - withdraw; printf("\nYour currant balance is %d",balance); break; case 3: printf("\nPlease Enter Amount to deposite:"); scanf("%d",&deposite); balance = balance + deposite; printf("\nYour currant balance is %d",balance); break; case 4: printf("THANKS FOR COMMING"); exit(0); } }while(choice<=4 && choice>0); }
run
|
edit
|
history
|
help
0
Please
log in
to post a comment.
new
Thread and Mutex Code
My C Code
18BCE2182 ASSESS_1 Q2-1
dcl
Euclides MIRAR
Area
A_141117_Primo02
B_141202_Cadenas01
bitwise manipulation
Please log in to post a comment.