Add python codes and for the chapter of

computational complexity.
Update Java codes.
Update Contributors.
This commit is contained in:
Yudong Jin
2022-11-25 20:12:20 +08:00
parent 83629f3d2c
commit daf25d5e64
17 changed files with 571 additions and 82 deletions

View File

@ -57,6 +57,7 @@ def find(nums, target):
return i
return -1
""" Driver Code """
if __name__ == "__main__":
""" 初始化数组 """

View File

@ -41,9 +41,8 @@ def find(head, target):
index += 1
return -1
"""
Driver Code
"""
""" Driver Code """
if __name__ == "__main__":
""" 初始化链表 """
# 初始化各个结点

View File

@ -8,9 +8,8 @@ import sys, os.path as osp
sys.path.append(osp.dirname(osp.dirname(osp.abspath(__file__))))
from include import *
"""
Driver Code
"""
""" Driver Code """
if __name__ == "__main__":
""" 初始化列表 """
list = [1, 3, 2, 5, 4]

View File

@ -8,7 +8,6 @@ import sys, os.path as osp
sys.path.append(osp.dirname(osp.dirname(osp.abspath(__file__))))
from include import *
""" 列表类简易实现 """
class MyList:
""" 构造函数 """
@ -71,9 +70,7 @@ class MyList:
return self._nums[:self._size]
"""
Driver Code
"""
""" Driver Code """
if __name__ == "__main__":
""" 初始化列表 """
list = MyList()