For i=1 to 10000
ForStart:
……
if …… Then Goto ForStart
next i

解决方案 »

  1.   


    For i=1 to 10000
    ……
    if …… Then Goto ForContinue
    ……
    ForContinue:
    next i
    或者楼上代码要修改:
    For i=1 to 10000
    ForStart:
    ……
    if …… Then
        i=i+1
        Goto ForStart
    end if
    next i
      

  2.   

    For i=1 to 10000
       do while true
          ...
          if ... Then exit do
          ...
          exit do
       loop
    next i
      

  3.   

    说实话,大家都有点想用Goto的意图,不过在C里面一般不太用Goto也只好这要做了要是有这么一条语句就好了给分了第一位兄弟有点小问题,那就是可能i不会变
      

  4.   

    说实话,大家都有点想用Goto的意图,不过在C里面一般不太用Goto也只好这要做了要是有这么一条语句就好了给分了第一位兄弟有点小问题:那就是i可能不会变