摘要:
拆开Tuple 交换位置 使用 Tuple 可以方便的交换两个数的位置,不用设临时变量。 阅读全文
posted @ 2017-07-01 21:14
2021年的顺遂平安君
阅读(245)
评论(0)
推荐(0)
摘要:
拆开Tuple lax_coordinates = (33.9425, -118.408056)latitude, longitude = lax_coordinates # tuple unpacking 交换位置 variable = (10,2... 阅读全文
posted @ 2017-07-01 21:14
2021年的顺遂平安君
阅读(58)
评论(0)
推荐(0)
摘要:
class aTest: def __repr__(self): return "This is an aTest class."a = aTest()print (a)class bTest: passb = bTest()pr... 阅读全文
posted @ 2017-07-01 18:36
2021年的顺遂平安君
阅读(51)
评论(0)
推荐(0)
摘要:
输出结果: 所以, 决定了直接打印一个实例时输出的字符串。 阅读全文
posted @ 2017-07-01 18:36
2021年的顺遂平安君
阅读(141)
评论(0)
推荐(0)
摘要:
The first thing to know about special methods is that they are meant to be called by the Python interpreter, and not by you. You don’t write my_object 阅读全文
posted @ 2017-07-01 18:25
2021年的顺遂平安君
阅读(369)
评论(0)
推荐(0)
摘要:
The first thing to know about special methods is that they are meant to be called by the Python interpreter, and not by you. Yo... 阅读全文
posted @ 2017-07-01 18:25
2021年的顺遂平安君
阅读(66)
评论(0)
推荐(0)
摘要:
a class with an abstract method cannot be instantiated (that is, we cannot create an instance by calling it) unless all of its abstract methods have b 阅读全文
posted @ 2017-07-01 12:27
2021年的顺遂平安君
阅读(489)
评论(0)
推荐(0)
摘要:
a class with an abstract method cannot be instantiated (that is, we cannot create an instance by calling it) unless all of it... 阅读全文
posted @ 2017-07-01 12:27
2021年的顺遂平安君
阅读(70)
评论(0)
推荐(0)
浙公网安备 33010602011771号