模拟ATM(C语言)

模拟ATM(C语言)

#include
#include
#include

void withdraw(int *p);

void deposit(int *p);

void check(int *p);

void login(int *p_balance,int *m1,int *a);

void regist(int *m1);

void write(int *p_balance,int *a,int *m1);

struct information
{
	char username[15];
	char number[10];
	char password[10];
	char balance[5];
}user[50];

int main( )

{	
    int in,i=1,balance=0,m=0,a1=0;

	int *p_balance;
	int *m1;
	int *a;
	p_balance=&balance;
	m1=&m;
	a=&a1;
	
    printf("Hello!\n\n\n");
	
	login(p_balance,m1,a); 

    for(i=1;i>0;i++)

    {

        printf("-----------faction list\n\n");

        printf("\n-----------input 1: withdraw\n");

        printf("\n-----------input 2: check your balance\n");

        printf("\n-----------input 3: deposit\n");
        
        printf("\n-----------input 4: register\n");

 

你可能感兴趣的:(c语言)