15. goto语句

创建日期:2024-07-10
更新日期:2025-02-01

goto.c

#include <stdio.h>

int main()
{
    int a = 2;
there:
    a += 2;
    if (a > 10)
    {
        goto end;
    }
    else
    {
        goto there;
    }
end:
    printf("end");
}