python --while 练习6

#python --while 练习6

#输出 1、2、3、4、5、6、8、9、10:

 

#!/usr/bin/env python
#-*- coding:utf8 -*-

num = 1

while num <= 10:
  if num == 7:
    num += 1
    continue
  print(num)
  num += 1

posted @ 2018-04-27 16:53  VV2018  阅读(76)  评论(0编辑  收藏  举报