#我想问一下要怎么修改才能让程序循环,我这个是 输入数字月份,会输出一个对应的英文缩写月份,但是一次只能输出一个,我想要让他输入完一个月份按下回车键后可以输入下一个月份要怎么弄?
```c
#include<stdio.h>
void menu()
{
printf("---------请输入月份---------\n");
}
int main()
{
int months;
menu();
scanf_s("%d",&months);
switch (months)
{
case 1:
printf("Jan.\n");
break;
case 2:
printf("Feb.\n");
break;
case 3:
printf("Mar.\n");
break;
case 4:
printf("Apr.\n");
break;
case 5:
printf("May.\n");
break;
case 6:
printf("Jun.\n");
break;
case 7:
printf("Jul.\n");
break;
case 8:
printf("Aug.\n");
break;
case 9:
printf("Sept.\n");
break;
case 10:
printf("Oct.\n");
break;
case 11:
printf("Nov.\n");
break;
case 12:
printf("Dec.\n");
break;
default: printf("输入错误!\n");
}
return 0;
}
```