关于 goto
#include<stdio.h>int main(void)
{
char ch;
while((ch=getchar())!='#')
{
if(ch=='\n')
continue;
printf("step 1\n");
if(ch=='c')
continue;
else if(ch=='b')
break;
else if(ch=='g')
goto laststep;
printf("step 2\n");
laststep:printf("step 3\n");
}
printf("done\n");
return 0;
}
用这个goto用法,输入q时,为什么会输出step 3?