训练场专题

ICode国际青少年编程竞赛- Python-5级训练场-多参数函数

ICode国际青少年编程竞赛- Python-5级训练场-多参数函数 1、 def go(a, b):Spaceship.step(2)Dev.step(a)Spaceship.step(b)Dev.turnRight()Dev.step(b)Dev.turnLeft()Dev.step(-a)Dev.turnLeft()Dev.step(3)Dev.step(-3)

ICode国际青少年编程竞赛- Python-5级训练场-函数练习2

ICode国际青少年编程竞赛- Python-5级训练场-函数练习2 1、 def get_item(a):Spaceship.step(1)Dev.step(a)Dev.turnLeft()Dev.step(1)Spaceship.step(1)Dev.turnRight()Dev.step(-a)Spaceship.step(1)get_item(3)get_item(

ICode国际青少年编程竞赛- Python-5级训练场-综合练习6

ICode国际青少年编程竞赛- Python-5级训练场-综合练习6 1、 for i in range(3):Dev.step(2 * (i + 1))Dev.turnLeft()while Flyer[2 - i].disappear():wait()Dev.step(2 * (i + 1))Dev.turnRight()while Dev.x != Item[i].x:

ICode国际青少年编程竞赛- Python-6级训练场-递归入门

ICode国际青少年编程竞赛- Python-6级训练场-递归入门 1、 def recur(n):# 边界条件if n<1:return# 额外动作Dev.step(n)Dev.turnRight()# 递归调用recur(n-1)recur(8) 2、 def recur(n):# 边界条件if n<1:return# 额外动作Dev.step(n)Dev.tu

ICode国际青少年编程竞赛- Python-4级训练场-综合训练4

ICode国际青少年编程竞赛- Python-4级训练场-综合训练4 1、 Dev.turnLeft()Dev.step(3)Dev.turnRight()Dev.step(3)Dev.turnLeft()Dev.step(4) 2、 for i in range(3):Dev.step(2)Dev.turnRight()while Flyer[i].disa

ICode国际青少年编程竞赛- Python-4级训练场-嵌套for循环练习2

ICode国际青少年编程竞赛- Python-4级训练场-嵌套for循环练习2 1、 for i in range(3):Dev.turnRight()for j in range(3):Dev.step(-3)Dev.turnRight()Dev.step(4-2*i) 2、 for i in range(6):for j in range(2):Dev.step(2

ICode国际青少年编程竞赛- Python-4级训练场-嵌套for循环入门

ICode国际青少年编程竞赛- Python-4级训练场-嵌套for循环入门 1、 for i in range(3):Dev.step(3)for j in range(3):Dev.turnLeft()Dev.step(-2)Dev.turnLeft() 2、 for i in range(3):Dev.turnLeft()Dev.step(4)Dev.turnRi

ICode国际青少年编程竞赛- Python-4级训练场-太阳能板1

ICode国际青少年编程竞赛- Python-4级训练场-太阳能板1 1、 Dev.step(3)Dev.turnRight()Dev.step(2)while Dev.energy < 60:wait()Dev.step(-6) 2、 Dev.step(7)while Dev.energy < 90:wait()Dev.step(-1)Dev.turnR

ICode国际青少年编程竞赛- Python-4级训练场-绿色能量1

ICode国际青少年编程竞赛- Python-4级训练场-绿色能量1 1、 Dev.step(3)Dev.turnLeft()Dev.step(3)Spaceship.step(4)Spaceship.turnRight()Spaceship.step(4)Dev.step(3)while Item[1].y != Dev.y:wait() 2、 Dev.

ICode国际青少年编程竞赛- Python-3级训练场-能量状态判断1

ICode国际青少年编程竞赛- Python-3级训练场-能量状态判断1 1、 for i in range(6):Spaceship.step(2)if not Item[i].broken():Spaceship.turnLeft()Spaceship.step(4)Spaceship.turnLeft()Spaceship.turnLeft()Spaceship.step

ICode国际青少年编程竞赛- Python-2级训练场-识别循环规律2

ICode国际青少年编程竞赛- Python-2级训练场-识别循环规律2 1、 for i in range(3):Dev.step(3)Dev.turnRight()Dev.step(4)Dev.turnLeft() 2、 for i in range(3):Spaceship.step(3)Spaceship.turnRight()Spaceship.step(1)

ICode国际青少年编程竞赛- Python-2级训练场-综合练习2

ICode国际青少年编程竞赛- Python-2级训练场-综合练习2 1、 Flyer[0].step()Flyer[1].step()Dev.step(4) 2、 for i in range(2):Flyer[i].step()Dev.step(2)Dev.turnLeft()Flyer[0].step(2)Dev.step(2) 3、 for

ICode国际青少年编程竞赛- Python-2级训练场-数独

ICode国际青少年编程竞赛- Python-2级训练场-数独 1、 Spaceship.step(3) 2、 Spaceship.step(3) 3、 Spaceship.step(1)Spaceship.turnLeft()Spaceship.step(1) 4、 Spaceship.step(3)Spaceship.turnRight

ICode国际青少年编程竞赛- Python-2级训练场-坐标与列表练习

ICode国际青少年编程竞赛- Python-2级训练场-坐标与列表练习 1、 for i in range(6):Spaceship.step(Item[i].x - Spaceship.x)Dev.step(Item[i].y - Dev.y)Dev.step(Spaceship.y - Dev.y) 2、 for i in range(5):Spaceship.

ICode国际青少年编程竞赛- Python-2级训练场-for循环练习2

ICode国际青少年编程竞赛- Python-2级训练场-for循环练习2 1、 for i in range(5):Dev.step(9 - i * 2)Dev.turnLeft() 2、 for i in range(3):Spaceship.step(i + 1)Spaceship.turnRight()Spaceship.step(i + 1)Spaceship

ICode国际青少年编程竞赛- Python-2级训练场-列表入门

ICode国际青少年编程竞赛- Python-2级训练场-列表入门 1、 Dev.step(3) 2、 Flyer.step(1)Dev.step(-2) 3、 Flyer.step(1)Spaceship.step(7) 4、 Flyer.step(5)Dev.turnRight()Dev.step(5)Dev.turnLeft()Dev

ICode国际青少年编程竞赛- Python-1级训练场-综合训练1

ICode国际青少年编程竞赛- Python-1级训练场-综合训练1 1、 Spaceship.turnLeft()for i in range(2):Spaceship.turnLeft()Spaceship.step(3)Dev.step(-1)Spaceship.step(4)Spaceship.turnLeft()Spaceship.step(3) 2、

ICode国际青少年编程竞赛- Python-1级训练场-多变量应用

ICode国际青少年编程竞赛- Python-1级训练场-多变量应用 1、 a = 1b = 2for i in range(4):Spaceship.step(a)Dev.step(b)Dev.step(-b)a = a + 1b = b + 1 2、 a = 2b = 5for i in range(3):Spaceship.turnLeft()Spaces

ICode国际青少年编程竞赛- Python-1级训练场-for循环与变量

ICode国际青少年编程竞赛- Python-1级训练场-for循环与变量 1、 a = 1for i in range(4):Spaceship.step(a)Dev.step(2)Dev.step(-2)a = a + 1 2、 a = 1for i in range(4):Spaceship.step(a)Dev.step(3)Dev.step(-3)a

ICode国际青少年编程竞赛- Python-1级训练场-变量入门

ICode国际青少年编程竞赛- Python-1级训练场-变量入门 1、 a = 4Dev.turnRight()Dev.step(a) 2、 a = 4Spaceship.step(a)Dev.step(a) 3、 a = 4Dev.step(a)Dev.turnLeft()Dev.step(a) 4、 a = 5Dev.step(a

ICode国际青少年编程竞赛- Python-1级训练场-基础训练1

ICode国际青少年编程竞赛- Python-1级训练场-基础训练1 1、 Dev.step(4) 2、 Dev.step(-4)Dev.step(8) 3、 Dev.turnLeft()Dev.step(4) 4、 Dev.step(3)Dev.turnLeft()Dev.step(-1)Dev.step(4) 5、 Dev.step

ICode国际青少年编程竞赛- Python-1级训练场-基础训练2

ICode国际青少年编程竞赛- Python-1级训练场-基础训练2 1、 a = 4 # 变量a存储的数字是4Dev.step(a) # 因为变量a的值是4,所以Dev.step(a)就相当于Dev.step(4) 2、 a = 1 # 变量a的值为1for i in range(4):Dev.step(a)Dev.turnLeft()a = a + 1 #

ICode国际青少年编程竞赛- Python-1级训练场-for循环入门

ICode国际青少年编程竞赛- Python-1级训练场-for循环入门 1、 for i in range(4):Dev.step(4)Dev.turnLeft() 2、 for i in range(3):Dev.step(6)Dev.turnRight() 3、 for i in range(3):Dev.turnRight()Dev.step(2)Dev

ICode国际青少年编程竞赛- Python-1级训练场-基本操作

ICode国际青少年编程竞赛- Python-1级训练场-基本操作 1、 Dev.step(3) 2、 Dev.step(1) 3、 Dev.step(7) 4、 Dev.step(-1) 5、 Dev.step(-5) 6、 Dev.step(3)Dev.step(-8) 7、 Dev.turnRight()Dev.ste

ICode国际青少年编程竞赛- Python-1级训练场-for循环练习

ICode国际青少年编程竞赛- Python-1级训练场-for循环练习 1、 for i in range(3):Dev.step(4)Dev.turnLeft() 2、 for i in range(3):Dev.step(2)Dev.turnRight()Dev.step(2)Dev.turnLeft() 3、 for i in range(3):De

ICode国际青少年编程竞赛- Python-1级训练场-路线规划

ICode国际青少年编程竞赛- Python-1级训练场-路线规划 1、 Dev.step(3)Dev.turnLeft()Dev.step(4) 2、 Dev.step(3)Dev.turnLeft()Dev.step(3)Dev.step(-6) 3、 Dev.step(-2)Dev.step(4)Dev.turnLeft()Dev.ste