|
|
|
@ -10,7 +10,7 @@ int num2;
|
|
|
|
|
int trytimes;
|
|
|
|
|
}specific;
|
|
|
|
|
specific informat[10];
|
|
|
|
|
int changesi(int p)
|
|
|
|
|
void changesi(int p)
|
|
|
|
|
{
|
|
|
|
|
if(p==0)
|
|
|
|
|
printf("+");
|
|
|
|
@ -59,7 +59,12 @@ printf("TRE AGAIN\n");
|
|
|
|
|
int main()
|
|
|
|
|
{
|
|
|
|
|
srand(time(NULL));
|
|
|
|
|
printf("----------pupil exercise system----------\n");
|
|
|
|
|
printf("----------pupil exercise system----------\n");
|
|
|
|
|
printf("\t\t\t*******************************************************\n");
|
|
|
|
|
printf("\t\t\t* 此次测试的题目有10道 *\n");
|
|
|
|
|
printf("\t\t\t* 题目类型为两位数的加减 *\n");
|
|
|
|
|
printf("\t\t\t* 每题10分,总分为100分。 *\n");
|
|
|
|
|
printf("\t\t\t*******************************************************\n");
|
|
|
|
|
int t=1,cnt=0,sum=0,a,b,c,ans;
|
|
|
|
|
while(t<=10)
|
|
|
|
|
{
|
|
|
|
@ -122,13 +127,11 @@ printf("--------------------\n");
|
|
|
|
|
}
|
|
|
|
|
show_rank(sum);
|
|
|
|
|
printf("\n\n");
|
|
|
|
|
char k;
|
|
|
|
|
int i;
|
|
|
|
|
for(i=1;i<=10;i++)
|
|
|
|
|
{
|
|
|
|
|
printf("第%d题:%d",i,informat[i].num1);
|
|
|
|
|
|
|
|
|
|
k=changesi(informat[i].jiajian);
|
|
|
|
|
changesi(informat[i].jiajian);
|
|
|
|
|
printf("%d=",informat[i].num2);
|
|
|
|
|
if(informat[i].jiajian==0)
|
|
|
|
|
printf("%d\n",informat[i].num1+informat[i].num2);
|
|
|
|
@ -141,6 +144,3 @@ p=sum/10.0;
|
|
|
|
|
printf("你的正确率是:%.2f%%\n",p*10);
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|