
Algorithm & Data Structure
文章平均质量分 50
你的程序员大叔
这个作者很懒,什么都没留下…
展开
-
D02-Array--leetcode - 217. Contains Duplicate
#217. Contains DuplicateGiven an integer array nums, return true if any value appears at least twice in the array, and return false if every element is distinct.Example 1:Input: nums = [1,2,3,1]Output: trueExample 2:Input: nums = [1,2,3,4]Output: fals转载 2022-10-20 07:26:27 · 147 阅读 · 1 评论 -
D01- leetcode 121. Best Time to Buy and Sell Stock
【代码】D01- leetcode 121. Best Time to Buy and Sell Stock。转载 2022-10-18 23:18:03 · 151 阅读 · 0 评论 -
大O记法-BigO notation
what is big O notation?The way that describe the relationship between the runing time and the size of problem.1- Method of calculating time complexity of algorithm.1)hypothesis(假设法)class solution{ int i = 0; while(i <= n){ i = i * 2; }}assumi原创 2021-09-01 08:27:13 · 627 阅读 · 0 评论