- 博客(3)
- 收藏
- 关注
原创 Python_pgzero小球抛物线运动
from math import ceil, sqrtimport pgzrun# 抛物线x = 100speed_x = 15 # 水平匀速y = 100a = 0.5 # 竖直自由落体t = 1count = 0def draw(): screen.fill('white') screen.draw.filled_circle((x, y), 30, 'red') # 动者变也,凡是运动就需要变量def update(): # 由于upda.
2021-07-16 22:50:23 1064
原创 python_打乱已知列表的顺序
import randomdef sort(): list_0 = ['A', 'B', 'C', 'D', 'E', 'F', 'G'] # 列表不能设置中间变量(等同于原变量) list_1 = [] while len(list_0) > 0: # 随机生成索引 x = random.randint(0, len(list_0) - 1) list_1.append(list_0[x]) list_0
2021-05-14 21:20:35 143
原创 JDBC中操作文件时的数据库、表、字段和文件的编码方式必须保持一致
我在学习JDBC插入longtext类型的文件时,main主程序如下(方法函数省略):public static void main(String[] args) throws Exception {File context = new File("G:/MySQL/test.txt"); Good good1 = new Good("耳机", 6, 7, 55, 1, 0,
2016-09-11 23:10:44 276
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人