Develop a program for students to practice spelling the names English of months.——c语言编程

问题描述:

Develop a program for students to practice spelling the names English of months.——c语言编程
Develop a program for students to practice spelling the names English of months.The Chinese names of the months are displayed randomly and the student needs to enter the corresponding English names.If the spelling is correct,display “Right”; otherwise display “Wrong”.When the student enters “end”,his score of the achievement is displayed and the program stops.The user interface is shown below.

#include "stdio.h"
char *MNT[] = {"January","Feburary","March","April","May","June","July","August","September","October","November","December"};
void main()
{
char x[0x200] = {0}
srand(time());
while(1)
{
int i = rand()%12;
printf("%d月:",i+1);
scanf(x,"%s",x);
if(strcmp(x,"end")==0)return;
if(strcmp(x,MNT[i])==0)
{
printf("Correct\n");
}
else
{
printf("Wrong\n");
}
}
}