热门

最新

红包

立Flag

投票

同城

我的

发布
code_lyb
Coder个人博客
4 年前
truecode_lyb

嵌入式学习之按键检测

嵌入式开发学习之--按键检测

CSDN App 扫码分享
分享
评论
点赞
打赏
  • 复制链接
  • 举报
下一条:
一个有意思的搞笑小错误,而且需要的代码也很少import turtle as t #导入turtle 模块from random import choice #导入choice模块def gaoxiao(): c=input("请输入密码:") if c == "123456": print("正确") else: for n in range(100): t.bgcolor("blue") #画布颜色 t.color("red") #画笔颜色 t.speed(500) #画笔速度 x = list(range(-800, 800)) y = list(range(-400, 400)) x1 = choice(x) #设置随机坐标 y1 = choice(y) t.penup() t.goto(x1,y1) for i in range(1) : t.pendown() m=list(range(10,50)) m1=choice(m) t.write("错误",font=("隶书",m1)) # 设置字体格式 t.hideturtle() t.done()gaoxiao() #调用
立即登录