All Projects

Bus Ticket Booking System in Python
Bus Ticket Booking System in Java
Bus Ticket Booking System in Cpp
Bus Ticket Booking System in C
Cafe Order System in Python
Cafe Order System in Java
Cafe Order System in Cpp
Cafe Order System in C
Social Media Account Details Manager in Python
Social Media Account Details Manager in Java
Social Media Account Details Manager in Cpp
Social Media Account Details Manager in C
Mini ATM in Python Language
Mini ATM in Java Language
Mini ATM in cpp language
Mini ATM in c language
Pocket Money Manager in Python Language
Pocket Money Manager in Java Language
Pocket Money Manager in Cpp Language
Pocket Money Manager in C Language
Username Password Generator in Python Language
Username Password Generator in Cpp Language
Username Password Generator in C Language
Telephone Directory in Python Language
Telephone Directory in Java Language
Telephone Directory in Cpp Language
Telephone Directory in C Language
Calander in Cpp Language
Calander in C Language
NoteBook in Python Language
NoteBook in Cpp Language
NoteBook in C Language
Voting System in Python Language
Voting System in Java Language
Voting System in Cpp Language
Voting System in C Language
Age Calculator in Python Language
Age Calculator in Java Language
Age Calculator in Cpp Language
Age Calculator in C Language
Currency Converter in Python Language
Currency Converter in Java Language
Currency Converter in Cpp Language
Currency Converter in C Language
Random Password Generator in python language
Random Password Generator in java language
Random Password Generator in cpp language
Random Password Generator in c language
Billing System in python language
Billing System in c++ language
Billing System in c language
Atm in c language

Atm in c language


Aniket The Programmer

1.22K+ Subscribers

Click To Subscribe My Channel

Subscribe

Source Code

        
#include <stdio.h>

int main(){
    float total_amount,transfer,deposite,withdraw,cheak_balance;
    int pin,password,user_input;

    printf("enter your password to enter in your account\n");
    scanf("%d", &password);
    printf("Enter amount to create account\n");
    scanf("%f", &total_amount);
    printf("Enter 1 for check balance.\nEnter 2 for deposit.\nEnter 3 for withdraw.\nEnter 4 for transfer.\n");
    scanf("%d", &user_input);
    printf("Enter pin\n");
    scanf("%d", &pin);
     
    if (pin==password)
    {
        switch (user_input)
        {
        case 1:
            printf("Your total balance in your account is %f", total_amount);
            break;
        case 2:
            printf("Enter amount to deposit\n");
            scanf("%f", &deposite);
            float net_balance_after;
            net_balance_after = total_amount + deposite;
            printf("Net balance after deposit is %f", net_balance_after);
            break;
        case 3:
            printf("Enter amount to withdraw\n");
            scanf("%f", &withdraw);
            float balance_after_withdraw;
            balance_after_withdraw = total_amount - withdraw;
            printf("Net balance after withdraw %f", balance_after_withdraw);
            break;
        case 4:
            printf("Enter amount to transfer\n");
            scanf("%f", &transfer);
            float balance_after_transfer;
            balance_after_transfer = total_amount - transfer;
            printf("Net balance after transfer is %f", balance_after_transfer);
            break;
        default:
            printf("Enter valid user input");
            break;
        }
    }
    else
    {
        printf("Your password is wrong. so repeat the process again");
    }
   
    return 0;
}

        
    

Source Code Github Link: View

View Video On Youtube Link: View

Next Topic

35k+ Coding Problems: Edocgram is collection of 35k+ coding problems Edocgram! 🎉