ATM???????????
???????????? ???????[ 2015/4/21 13:40:06 ] ??????????????? ATM?? ?????
void referCard(int *a??int *b);
void refersecret(int *a??int i);
int main(void)
{
int idCard[5] = {111??222??333??444??555};
int secretCard[5] = {11??22??33??44??55};
referCard(idCard??secretCard);
return 0;
}
//??????
void refersecret(int *a??int i)
{
int secret=0??num=0??num_1=0;
do{
printf("??????????????");
scanf("%d"??&secret);
if(secret==a[i]){
do{
printf("????????????100-50000??100??????????");
scanf("%d"??&num);
if (num<100||num>50000||num%100!=0) {
printf("????????
");
}
}while(num<100||num>50000||num%100!=0);
printf("??????
");
break;
}else{
num_1++;
}
if (num_1==3) {
printf("???????п????????24С?????????
");
break;
}
}while(1);
}
//?????????
void referCard(int *a??int *b)
{
int id=0??i=0??choice=0;
bool m=0;
do{
printf("??????????е??????
?????????1
?????????2
?????????3
?????????4
");
scanf("%d"??&choice);
if (choice!=1) {
printf("?ù?????δ???????????????");
}
}while(choice!=1);
do{
printf("??????????????");
scanf("%d"??&id);
for (; i<6; i++) {
if (a[i]==id) {
m=1;
break;
}
if (i==5) {
printf("???????????
");
}
}
}while(m==0);
refersecret(b??i);
}
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11