文章
leetcode 268 Missing Number
题目详情<blockquoteGivenanarraycontainingndistinctnumberstakenfrom0,1,2,...,n,findtheonethatismissingfromthearray.<p题目的意思是
leetcode 219 Contains Duplicate II
题目详情<blockquoteGivenanarrayofintegersandanintegerk,findoutwhethertherearetwodistinctindicesiandjinthearraysuchthatnum
leetcode 169 Majority Element
题目详情<blockquoteGivenanarrayofsizen,findthemajorityelement.Themajorityelementistheelementthatappearsmorethan⌊n/2⌋times.Y
leetcode 217 Contains Duplicate
题目详情<blockquoteGivenanarrayofintegers,findifthearraycontainsanyduplicates.Yourfunctionshouldreturntrueifanyvalueappearsat
算法题解:从条形图中找出最大矩形(扫描过程中维护信息树/信息栈)
题目分析题目链接:https://leetcode.com/problems...(https://link.segmentfault.com/?enciH%2BvDroQQeB1oYI4mO6%2BKA%3D%3D.sDOq%2FnfvgTa4NwnSh7l4JegbKMDw2w
一维滑动窗口(SlidingWindow)
滑动窗口(SlidingWindow)问题经常使用快慢指针(slow,fastpointer)0,slow) 的区域为滑动窗口已经探索过的区域slow,fast的区域为滑动窗口正在探索的区域(fast,endofarray)为待探索的区域SlidingWindow的问题主
算法题解:找出给定表达式所有可能的计算次序(递归分治改进为动态规划)
题目分析题目链接:https://leetcode.com/problems...(https://link.segmentfault.com/?encQYg%2B%2BKGSELS7oQSyUiOMIA%3D%3D.1uo4w8nJ0IfnSQYh9Zywr4kernXml2zM
Leetcode之Union-Find(并查集)
并查集(UnionFind)包括查询(Find)和联合(Union),主要使用不相交集合(DisjointSets)查询(Find)主要是用来决定不同的成员是否在一个子集合之内联合(Union)主要是用来把多个子集合成一个集合UnionFind的实际运用:1.计算机网络检查集群
leetcode 167 Two Sum II - Input array is sorted
题目详情<blockquoteGivenanarrayofintegersthatisalreadysortedinascendingorder,findtwonumberssuchthattheyadduptoaspecifictarg
LeetCode 关于回溯问题的看法
<blockquote回溯算法(BackTrack)在算法过程中就是类似于枚举算法,尝试在搜索过程中找到问题的解。</blockquote使用回溯算法解题的一般步骤使用回溯算法解题的一般步骤:针对所给问题得出一般的解空间用回溯搜索方法搜索解空间使用深度
已加载文章中没有匹配内容,试试其他关键词或清空搜索。