mirror of
https://github.com/Hizenberg469/Python-tutorial.git
synced 2026-04-19 15:12:22 +03:00
18 lines
254 B
Python
18 lines
254 B
Python
#Implementing List:
|
|
|
|
class SuperList(list):
|
|
def __len__(self):
|
|
return 1000
|
|
|
|
|
|
super_list1 = SuperList()
|
|
|
|
print(len(super_list1))
|
|
|
|
super_list1.append(5)
|
|
|
|
print(super_list1[0])
|
|
|
|
print(issubclass(SuperList, list))
|
|
|
|
print(issubclass(list, object)) |