goc编程指令

2022-05-19 12:52:16   文档大全网     [ 字体: ] [ 阅读: ]

#文档大全网# 导语】以下是®文档大全网的小编为您整理的《goc编程指令》,欢迎阅读!
指令,编程,goc
第二课



前进100pen.fd(100);

后退100pen.bk(100);

左转90度:pen.lt(90);

右转90度:pen.rt(90);



int main() {

pen.show(); pen.speed(6);

pen.fd(60); pen.rt(90); pen.fd(20); pen.rt(90); pen.fd(20); pen.rt(90); pen.fd(20);

return 0; }



40

前进100pen.fd(100); 后退100pen.bk(100); 左转90度:pen.lt(90); 右转90度:pen.rt(90);

int main() {

pen.show(); pen.speed(6);

pen.fd(60); pen.lt(90); pen.fd(40);

return 0; }

20

40

60

30

30

int main() {

pen.show(); pen.speed(6);

pen.fd(60); pen.bk(30); pen.lt(90); pen.fd(30); pen.bk(60);

return 0; }

30

int main() {

pen.show(); pen.speed(6);

pen.lt(90); pen.fd(30); pen.rt(90); pen.fd(30); pen.rt(90); pen.fd(30); pen.lt(90); pen.fd(30); pen.lt(90); pen.fd(30);



return 0; }


本文来源:https://www.wddqxz.cn/0ec84c04b8f3f90f76c66137ee06eff9aff849cb.html

相关推荐