摘要: import sqlite3 conn=sqlite3.connect('mrsoft.db') cursor=conn.cursor() cursor.execute('create table user (id int(10) primary key name varchar(20))') cu 阅读全文
posted @ 2022-12-16 01:47 核变的思 阅读(34) 评论(0) 推荐(0)
摘要: print('\n','='*10,'蚂蚁庄园动态','='*10) with open('message.txt','w') as file: pass print('\n即将显示....\n') print('\n','='*10,'蚂蚁庄园动态','='*10) file=open('mess 阅读全文
posted @ 2022-12-16 01:40 核变的思 阅读(47) 评论(0) 推荐(0)
摘要: def division(): print('\n 分苹果了 \n') apple=int(input('请输入苹果的个数')) children=int(input('请输入来了多少个小朋友')) result=apple//children remain=apple-result*childre 阅读全文
posted @ 2022-12-16 01:34 核变的思 阅读(23) 评论(0) 推荐(0)
摘要: bmi.py def fun_bmi(person,height,weight): print(person+'的身高'+str(height)+'米\t 体重:'+str(weight)+'千克') bmi=weight/(height*height) print(person+'的BMI指数为: 阅读全文
posted @ 2022-12-16 01:31 核变的思 阅读(41) 评论(0) 推荐(0)
摘要: class Geese: '''大雁类''' def __init__(self,beak,wing,claw): print('我是大雁类!我有以下特征:') print(beak) print(wing) print(claw) def fly(self,state): print(state) 阅读全文
posted @ 2022-12-16 01:28 核变的思 阅读(33) 评论(0) 推荐(0)
摘要: def function_tips(): import datetime mot=["今天星期一:\n坚持下去不是因为我很坚强,而是因为我别无选择。", "今天星期二:\n含泪播种的人一定能笑着收获。", "今天星期三:\n作对的事情比把事情做对更重要。", "今天星期四:\n命运给予我们的不是失望 阅读全文
posted @ 2022-12-16 01:22 核变的思 阅读(24) 评论(0) 推荐(0)
摘要: import turtle, datetime def drawGap(): # 绘制数码管间隔 turtle.penup() turtle.fd(5) def drawLine(draw): # 绘制单段数码管 drawGap() turtle.pendown() if draw else tur 阅读全文
posted @ 2022-12-08 15:58 核变的思 阅读(81) 评论(0) 推荐(0)
摘要: import sys import pygame pygame.init() size = width, height = 640, 480 screen = pygame.display.set_mode(size) color = (0, 0, 0) ball = pygame.image.lo 阅读全文
posted @ 2022-12-01 21:53 核变的思 阅读(111) 评论(0) 推荐(0)
摘要: str1 = '马走日' str2 = ',' str3 = '象走田' str4 = ',' str5 = '车走直线炮翻山' str6 = '士走斜线护将边' str7 = '小卒一去不复还' str8 = '。' print("象棋口诀"+':') print(str1 + str2) pri 阅读全文
posted @ 2022-10-08 13:45 核变的思 阅读(60) 评论(0) 推荐(0)
摘要: import datetime # 定义一个列表 mot = ["今天星期一: \n坚持下去不是因为我很坚强,而是因为我别无选择。", "今天星期二: \n含泪播种的人一定能笑着收获。", "今天星期三: \n做对的事情比把事情做对重要。", "今天星期四: \n命运给予我们的不是失望之酒,而是机会 阅读全文
posted @ 2022-09-29 00:33 核变的思 阅读(54) 评论(0) 推荐(0)