📜  如何重新启动循环python代码示例

📅  最后修改于: 2022-03-11 14:45:30.912000             🧑  作者: Mango

代码示例1
i=2
while i < n:
    if something:
       do something
       i += 1
    else: 
       do something else  
       i = 2 #restart the loop