摘要:
list_a = [1, 2, 3] list_d = [i for i in list_a]#[1, 2, 3] list_e = [i*j for i in list_a for j in list_c]#[4,5,6,10,12,12,15,18] list_f = [i*j for i,j 阅读全文
posted @ 2022-08-30 16:49
遇事不决,量子力学
阅读(36)
评论(0)
推荐(0)
摘要:
python中保留n位小数,可以使用round 函数 a = 34.564636856845754print(round(a, 2))print(round(a, 3)) 阅读全文
posted @ 2022-08-30 16:01
遇事不决,量子力学
阅读(356)
评论(0)
推荐(0)
摘要:
from django.test import TestCase# Create your tests here.class A: def __init__(self): self.a = "a" print("A")class B: def __init__(self): self.b = "b" 阅读全文
posted @ 2022-08-30 15:50
遇事不决,量子力学
阅读(32)
评论(0)
推荐(0)