E-COM-NET
首页
在线工具
Layui镜像站
SUI文档
联系我们
推荐频道
Java
PHP
C++
C
C#
Python
Ruby
go语言
Scala
Servlet
Vue
MySQL
NoSQL
Redis
CSS
Oracle
SQL Server
DB2
HBase
Http
HTML5
Spring
Ajax
Jquery
JavaScript
Json
XML
NodeJs
mybatis
Hibernate
算法
设计模式
shell
数据结构
大数据
JS
消息中间件
正则表达式
Tomcat
SQL
Nginx
Shiro
Maven
Linux
Explanation
leetcode 530. Minimum Absolute Difference in BST
Givenabinarysearchtreewithnon-negativevalues,findtheminimumabsolutedifferencebetweenvaluesofanytwonodes.Example:Input:1\3/2Output:1
Explanation
accumulate_zhang
·
2020-09-15 16:34
leetcoding
in
python
python
leetcode
with
python&java
最长递增子序列(LIS)
例如:Input:[10,9,2,5,3,7,101,18]Output:4
Explanation
:Thelongestincreasingsubsequenceis[2,3,7,101],thereforethelengthis4
萝卜头柯克船长
·
2020-09-15 16:35
Java练习--三角形计算
yourtaskistocountthenumberoftripletschosenfromthearraythatcanmaketrianglesifwetakethemassidelengthsofatriangle.Example1:Input:[2,2,3,4]Output:3
Explanation
开到靡荼
·
2020-09-15 13:59
Java
【DP】LeetCode - 120. Triangle、贝壳找房“采木头,锯子斧头”问题
输入:320402010425901005输出:139
Explanation
:第一棵树用斧头砍(40),第二颗树还用斧头(4),第三棵树,换成锯子(5+90) 在牛客上看题,看到了一道用锯子斧头砍
Bob__yuan
·
2020-09-15 07:36
LeetCode
Algorithm
#
编程题
LeetCode
dp
leetcode.637 二叉树的层平均值(java实现)
returntheaveragevalueofthenodesoneachlevelintheformofanarray.Example1:Input:3/\920/\157Output:[3,14.5,11]
Explanation
超悦人生
·
2020-09-15 06:17
#
二叉树
Leetcode
算法题目
leetcode 132. Palindrome Partitioning II
partitionssuchthateverysubstringofthepartitionisapalindrome.Returntheminimumcutsneededforapalindromepartitioningofs.Example:Input: "aab"Output:1
Explanation
SomeOtherTime
·
2020-09-15 06:03
[leetcode] 279. Perfect Squares
findtheleastnumberofperfectsquarenumbers(forexample,1,4,9,16,…)whichsumton.Example1:Input:n=12Output:3
Explanation
农民小飞侠
·
2020-09-15 05:52
leetcode
C++
leetcode题解
剑指 offer第60题-n 个骰子的点数
Input:n=1Output:[[1,0.17],[2,0.17],[3,0.17],[4,0.17],[5,0.17],[6,0.17]]
Explanation
:Throwadice,thesumofthenumbersfacingupmaybe1,2,3,4,5,6
ritagreen123
·
2020-09-15 05:43
算法题
剑指
offer
计算二叉树每层平均值
returntheaveragevalueofthenodesoneachlevelintheformofanarray.Example1:Input:3/\920/\157Output:[3,14.5,11]
Explanation
LHaoRax
·
2020-09-15 05:38
数据结构
数据结构
leetcode
二叉树
leetcode3. Longest Substring Without Repeating Characters(最长不重复子串)
Givenastring,findthelengthofthelongestsubstringwithoutrepeatingcharacters.Example1:Input:“abcabcbb”Output:3
Explanation
汝之宿命
·
2020-09-15 05:33
leetcode
Leetcode之Ugly Number II
Writeaprogramtofindthen-thuglynumber.Uglynumbersarepositivenumberswhoseprimefactorsonlyinclude2,3,5.Example:Input:n=10Output:12
Explanation
一只荣
·
2020-09-15 05:10
leetcode和机试题
leetcode
leetcode-198强盗抢劫(动态规划)
Input:[2,7,9,3,1]Output:12
Explanation
:Robhouse1(money=2),robhouse
WXX_DLUT
·
2020-09-15 05:53
C++
动态规划
LeetCode : 279. Perfect Squares 数值平方和最小个数
findtheleastnumberofperfectsquarenumbers(forexample,1,4,9,16,…)whichsumton.Example1:Input:n=12Output:3
Explanation
青盏
·
2020-09-15 05:08
LeetCode
Python实现"第三大的数"的两种方法
要求算法时间复杂度必须是O(n)Example1:Input:[3,2,1]Output:1
Explanation
:Thethirdmaximumis1.Example2:Input:[1,2]Output
求兵
·
2020-09-15 05:03
Algorithms
[leetcode] 712. Minimum ASCII Delete Sum for Two Strings
findthelowestASCIIsumofdeletedcharacterstomaketwostringsequal.Example1:Input:s1="sea",s2="eat"Output:231
Explanation
农民小飞侠
·
2020-09-15 03:22
leetcode
C++
leetcode题解
2. Add Two Numbers
leetcodelinkInput:(2->4->3)+(5->6->4)Output:7->0->8
Explanation
:342+465=807.思路:两个链表,
小明17
·
2020-09-15 00:57
3.Longest Substring Without Repeating Characters
leetcodelinkGivenastrings,findthelengthofthelongestsubstringwithoutrepeatingcharacters.Example1:Input:s="abcabcbb"Output:3
Explanation
小明17
·
2020-09-14 23:01
4.Median of Two Sorted Arrays
leetcodelinkExample1:Input:nums1=[1,3],nums2=[2]Output:2.00000
Explanation
:mergedarray=[1,2,3]andmedianis2
小明17
·
2020-09-14 23:58
[leetcode]300. Longest Increasing Subsequence
LongestIncreasingSubsequenceAnalysisrainingoutside…——[每天刷题并不难0.0]Givenanunsortedarrayofintegers,findthelengthoflongestincreasingsubsequence.
Explanation
你看见我的代码了么
·
2020-09-14 20:36
LeetCode
Medium
DP
Binary
Search
leetcode
[leetcode]131. Palindrome Partitioning
partitionssuchthateverysubstringofthepartitionisapalindrome.Returnallpossiblepalindromepartitioningofs.
Explanation
你看见我的代码了么
·
2020-09-14 20:36
LeetCode
Medium
recursive
【Leetcode】300.最长上升子序列(Longest Increasing Subsequence)
Input:[10,9,2,5,3,7,101,18]Output:4
Explanation
:Thelongestincreasingsubsequenceis[2,3,7,101],thereforethelengthis4
str_818
·
2020-09-14 19:26
LeetCode
动态规划
贪心专题6 - leetcode121. Best Time to Buy and Sell Stock/69. Sqrt(x) - Easy
例子Example1:Input:[7,1,5,3,6,4]Output:5
Explanation
:Buyonday2(price=1)andsellonday
落木~
·
2020-09-14 18:23
Leetcode
[Leetcode学习]Perform String Shifts(字符串移位)
输入输出案例:Input:s="abcdefg",shift=[[1,1],[1,1],[0,2],[1,3]]Output:"efgabcd"
Explanation
qq_28033719
·
2020-09-13 22:46
Java
LeetCode 241. Different Ways to Add Parentheses
returnallpossibleresultsfromcomputingallthedifferentpossiblewaystogroupnumbersandoperators.Thevalidoperatorsare+,-and*.Example1:Input:"2-1-1"Output:[0,2]
Explanation
i_chase
·
2020-09-13 16:25
189. Rotate Array python
rotatethearraytotherightbyksteps,wherekisnon-negative.Example1:Input:[1,2,3,4,5,6,7]andk=3Output:[5,6,7,1,2,3,4]
Explanation
qq_18884827
·
2020-09-13 16:59
leetcode
0320 java 滑动窗口
findtheminimallengthofacontiguoussubarrayofwhichthesum≥s.Ifthereisn’tone,return0instead.Example:Input:s=7,nums=[2,3,1,2,4,3]Output:2
Explanation
或许快要下雪了吧
·
2020-09-13 09:02
java刷code
【Leetcode】62. 不同的路径(Unique Paths)
Input:m=3,n=2Output:3
Explanation
:Fromthetop-leftcorner,thereareatotalof3waystoreachthebottom-rightcorner
str_818
·
2020-09-13 05:39
LeetCode
动态规划
leetcode
动态规划
DP
Separating Axis Theorem (SAT)
Explanation
SeparatingAxisTheorem(SAT)ExplanationPostedonMay24,2009SeparatingAxisTheorem(SAT)isatechniqueforcalculatingcollisionsbetweenconvexpolygons.I’mbynomeansanexpertonit,butaftertheneedaroseformetodosomecol
linuxheik
·
2020-09-13 05:25
obb
踫撞检测 之一 — 关于分离轴理论的解释(Separating Axis Theorem (SAT)
Explanation
)(完整翻译)
因为有踫撞方面的活要干,所以顺便翻译一下这篇文章—关于分离轴理论的解释(SeparatingAxisTheorem(SAT)
Explanation
)(完整翻译)有些意译的会放上原文参考,有错的地方留言指正
S_clifftop
·
2020-09-13 04:15
Tras
collision
SAT
奥力给
多边形踫撞检测
[LeetCode][458] Poor Pigs题解
[LeetCode][458]PoorPigs题解题解:https://leetcode.com/problems/poor-pigs/discuss/94266/Another-
explanation
-and-solution
AdaMeta
·
2020-09-13 01:51
leetcode
LeetCode刷题Medium篇寻找字符串中最长的不重复子串(滑动窗口解法)
Givenastring,findthelengthofthelongestsubstringwithoutrepeatingcharacters.Example1:Input:"abcabcbb"Output:3
Explanation
hanruikai
·
2020-09-12 22:19
面试题
java常见知识
[leetcode] 974. Subarray Sums Divisible by K
(contiguous,non-empty)subarraysthathaveasumdivisiblebyK.Example1:Input:A=[4,5,0,-2,-3,1],K=5Output:7
Explanation
农民小飞侠
·
2020-09-12 20:19
python
leetcode题解
Longest Valid Parentheses(动态规划)
’and‘)’,findthelengthofthelongestvalid(well-formed)parenthesessubstring.Example1:Input:“(()”Output:2
Explanation
Vilinzz
·
2020-09-12 20:11
c++
算法
算法
LeetCode 32. Longest Valid Parentheses(最长有效括号,C++)
’and‘)’,findthelengthofthelongestvalid(well-formed)parenthesessubstring.Example1:Input:“(()”Output:2
Explanation
重学CS
·
2020-09-12 19:21
Leetcode
最长不重复的子串长度
Givenastring,findthelengthofthelongestsubstringwithoutrepeatingcharacters.Example1:Input:"abcabcbb"Output:3
Explanation
tangyuan_sibal
·
2020-09-12 14:40
LeetCode中等难度刷题
[LeetCode] 159. Longest Substring with At Most Two Distinct Characters 最多有两个不同字符的最长子串...
findthelengthofthelongestsubstringtthatcontainsatmost2distinctcharacters.Example1:Input:"eceba"Output:3
Explanation
weixin_30362083
·
2020-09-12 07:57
[LeetCode] 907. Sum of Subarray Minimums
contiguous)subarrayofA.Sincetheanswermaybelarge,returntheanswermodulo10^9+7.Example1:Input:[3,1,2,4]Output:17
Explanation
aique3350
·
2020-09-12 05:40
Leetcode: 209. Minimum Size Subarray Sum
findtheminimallengthofacontiguoussubarrayofwhichthesum≥s.Ifthereisn'tone,return0instead.Example:Input:s=7,nums=[2,3,1,2,4,3]Output:2
Explanation
yexianyi
·
2020-09-12 04:51
LeetCode
LeetCode
Python实现"打家劫舍"的一种方法
如果两间相邻的房屋在同一晚上被小偷闯入,系统会自动报警给定一个代表每个房屋存放金额的非负整数数组,计算你在不触动警报装置的情况下,能够偷窃到的最高金额Example1:Input:[1,2,3,1]Output:4
Explanation
求兵
·
2020-09-12 03:34
Algorithms
Python实现"加一"的两种方法
给定一个非空的数值数组代表一个非负整数,对整数进行加一操作整数最高位存放在数组头位,数组中每一个元素都代表一个数字你可以认为整数不以0开头,除了数字0以外Example1:Input:[1,2,3]Output:[1,2,4]
Explanation
求兵
·
2020-09-12 00:54
Algorithms
leetcode【199】【tag Tree】Binary Tree Right Side View【c++版本,层次遍历,DFS两种方法】
returnthevaluesofthenodesyoucanseeorderedfromtoptobottom.Example:Input: [1,2,3,null,5,null,4]Output: [1,3,4]
Explanation
凡凡.cs
·
2020-09-11 14:45
【CODE】卡塔兰数列应用——二叉搜索树的个数
Example:Input:3Output:5
Explanation
:Givenn=3,thereareatotalof5uniqueBST'
Li_JiaQian
·
2020-09-11 07:02
C/C++
Leetcode637. BFS计算二叉树每层节点的平均值
Leetcode637.AverageofLevelsinBinaryTree题目Input:3/\920/\157Output:[3,14.5,11]
Explanation
:Theaveragevalueofnodesonlevel0is3
obrcnh
·
2020-09-11 02:44
leetcode算法
leetcode刷题(java)——nums【3】
Givenastring,findthelengthofthelongestsubstringwithoutrepeatingcharacters.Example1:Input:"abcabcbb"Output:3
Explanation
Harold.li
·
2020-09-10 22:54
leetcode
172. Factorial Trailing Zeroes
Example1:Input:3Output:0
Explanation
:3!=6,notrailingzero.Example2:Input:5Output:1
Explanation
:5!
xdhc304
·
2020-09-10 21:55
leetcode
LeetCode56. Merge Intervals(C++)
mergealloverlappingintervals.Example1:Input:[[1,3],[2,6],[8,10],[15,18]]Output:[[1,6],[8,10],[15,18]]
Explanation
Brielleqqqqqqjie
·
2020-09-10 16:31
Leetcode
leetcode-56. Merge Intervals 合并区间
mergealloverlappingintervals.Example1:Input:[[1,3],[2,6],[8,10],[15,18]]Output:[[1,6],[8,10],[15,18]]
Explanation
别说话写代码
·
2020-09-10 15:56
数据结构/算法/刷题
#
简单易懂的零知识证明说明 An intuitive
explanation
of zero knowledge theory for dummies
Anintuitiveexplanationofzeroknowledgetheoryfordummies(Fromhttps://github.com/jancarlsson/snarklib)Wearewellacquaintedwithencryptionofdata.Plaintextisencryptedintociphertext.Ideally,thisciphertextisnot
mutourend
·
2020-09-10 15:33
LeetCode 56. Merge Intervals C++ 比较器 与 Python 两种语言
mergealloverlappingintervals.Example1:Input:[[1,3],[2,6],[8,10],[15,18]]Output:[[1,6],[8,10],[15,18]]
Explanation
mooe1011
·
2020-09-10 15:20
LeetCode
C++
Python
【leetcode】-191. Number of 1 Bits 数字二进制表示1的个数
Writeafunctionthattakesanunsignedintegerandreturnthenumberof‘1’bitsithas(alsoknownastheHammingweight).Example1:Input:00000000000000000000000000001011Output:3
Explanation
turbo624
·
2020-08-26 15:15
LeetCode
上一页
4
5
6
7
8
9
10
11
下一页
按字母分类:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
其他