当前位置:网站首页>慧通编程入门课程 - 2A闯关
慧通编程入门课程 - 2A闯关
2022-07-06 18:51:00 【中学生信竞】
以下代码中双斜杠后面的内容是刘老师的注释,不需要同学们输入
前进100
int main() {
//pen:画笔
//fd:前进
//pen.fd(100):画笔前进100步
pen.fd(100);
return 0;
}
横向前进100
int main() {
//rt:右转
//pen.rt(90):画笔右转90度
pen.rt(90);
pen.fd(100);
return 0;
}
画7字
int main() {
pen.fd(200);
//lt:左转
//pen.lt(90):画笔左转90度
pen.lt(90);
pen.fd(100);
return 0;
}
画U形
int main() {
pen.fd(200);
//pen.rt(90).fd(150):画笔右转90度,前进150步
pen.rt(90).fd(150);
//hide:隐藏
//pen.rt(90).fd(200).hide(); 画笔右转90度,前进200步,隐藏
pen.rt(90).fd(200).hide();
return 0;
}
画T形
int main() {
pen.fd(200).rt(90);
//bk:后退
//pen.fd(100).bk(200):画笔前进100,后退200
pen.fd(100).bk(200);
pen.hide();
return 0;
}
画十字形
int main() {
//pen.fd(100).bk(200):画笔前进100步,后退200步
pen.fd(100).bk(200);
//pen.fd(100).rt(90):画笔前进100步,右转90度
pen.fd(100).rt(90);
pen.fd(100).bk(200);
return 0;
}
边栏推荐
- 企业中台建设新路径——低代码平台
- Web3's need for law
- CDB PDB user rights management
- 所谓的消费互联网仅仅只是做行业信息的撮合和对接,并不改变产业本身
- TiFlash 源码阅读(四)TiFlash DDL 模块设计及实现分析
- Zhang Ping'an: accelerate cloud digital innovation and jointly build an industrial smart ecosystem
- Real project, realized by wechat applet opening code (end)
- Tiflash source code reading (IV) design and implementation analysis of tiflash DDL module
- C#/VB.NET 删除Word文档中的水印
- The third season of ape table school is about to launch, opening a new vision for developers under the wave of going to sea
猜你喜欢
Lumion 11.0 software installation package download and installation tutorial
Draco - gltf model compression tool
豆瓣平均 9.x,分布式领域的 5 本神书!
Station B's June ranking list - feigua data up main growth ranking list (BiliBili platform) is released!
fiddler的使用
【服务器数据恢复】raid损坏导致戴尔某型号服务器崩溃的数据恢复案例
leetcode:736. Lisp 语法解析【花里胡哨 + 栈 + 状态enumaotu + slots】
Lombok makes the pit of ⽤ @data and @builder at the same time
Web3对法律的需求
postgresql之整体查询大致过程
随机推荐
Collection recommandée!! Quel plug - in de gestion d'état flutter est le plus fort? Regardez le classement des manons de l'île, s'il vous plaît!
Word wrap when flex exceeds width
1 -- Xintang nuc980 nuc980 porting uboot, starting from external mx25l
FLIR blackfly s usb3 industrial camera: how to use counters and timers
Gee upgrade can realize one piece of run tasks
Stm32f4 --- PWM output
4 -- Xintang nuc980 mount initramfs NFS file system
C#/VB. Net to delete watermarks in word documents
CDB PDB user rights management
如何从0到1构建32Core树莓派集群
argo workflows源码解析
[leetcode]Search for a Range
The empirical asset pricing package (EAP) can be installed through pypi
[C # notes] reading and writing of the contents of text files
Web3对法律的需求
Metaforce force meta universe development and construction - fossage 2.0 system development
leetcode:5. 最长回文子串【dp + 抓着超时的尾巴】
Schedulx v1.4.0 and SaaS versions are released, and you can experience the advanced functions of cost reduction and efficiency increase for free!
[paper reading | deep reading] anrl: attributed network representation learning via deep neural networks
Apifox,你的API接口文档卷成这样了吗?