Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/algorithm004-03/algorithm004-03
/ functions
Functions
7,451 in github.com/algorithm004-03/algorithm004-03
⨍
Functions
7,451
◇
Types & classes
3,321
↓ 2 callers
Method
get
(char ch)
Week 06/id_698/LeetCode_208_698.java:24
↓ 2 callers
Method
get
(char ch)
Week 06/id_588/LeetCode_208_588.java:66
↓ 2 callers
Method
get
(int key)
Week 07/id_618/LeetCode_146_618.java:11
↓ 2 callers
Method
get
(int key)
Week 07/id_253/LeetCode_146_253.java:43
↓ 2 callers
Method
get
(int key)
Week 07/id_138/LeetCode_146_138.java:24
↓ 2 callers
Method
get
(int key)
Week 07/id_418/LeetCode_146_418.java:51
↓ 2 callers
Method
get
(int key)
Week 07/id_598/LeetCode_146_598.java:69
↓ 2 callers
Method
get
:type key: int :rtype: int
Week 07/id_738/LeetCode_146_738.py:15
↓ 2 callers
Method
get
(int key)
Week 07/id_468/leetcode146_7_468.java:28
↓ 2 callers
Method
getBits
(int i)
Week 07/id_598/LeetCode_338_598.java:17
↓ 2 callers
Method
getCount
()
Week 06/id_653/LeetCode_547_653.java:20
↓ 2 callers
Method
getDiffCharNum
(String a, String b)
Week 03/id_063/LeetCode_127_063.java:28
↓ 2 callers
Method
getEndNode
(text string)
Week 06/id_733/LeetCode_208_733.go:50
↓ 2 callers
Function
getKey
(x, y int)
Week 03/id_733/LeetCode_874_733.go:46
↓ 2 callers
Method
getNode
(char c)
Week 06/id_363/LeetCode_208_363.java:96
↓ 2 callers
Method
getPath
(TreeNode currentNode,TreeNode searchedNode,List path,List resultPath)
Week 02/id_143/LeetCode_236_143.java:34
↓ 2 callers
Method
getPatterns
(String word)
Week 03/id_618/LeetCode_127_618.java:71
↓ 2 callers
Method
getRear
Get the last item from the deque.
Week 01/id_418/LeetCode_641_418.java:230
↓ 2 callers
Method
getTrieNode
(String word)
Week 06/id_558/LeetCode_212_558.java:81
↓ 2 callers
Method
getTrieNode
(String word)
Week 06/id_558/LeetCode_208_558.java:49
↓ 2 callers
Method
hammingWeight
(int n)
Week 07/id_613/java/src/main/Leetcode191.java:6
↓ 2 callers
Method
hammingWeight
输入的是一个无符号整数,返回其二进制表达式中1的个数 1.for循环 : 1.判断最后一位是否是1 然后向右移动一位 2.位运算 x = x & (x - 1) 清零最后一位的1 @param n @return
Week 07/id_363/LeetCode_191_363.java:26
↓ 2 callers
Method
hammingWeight2
(int n)
Week 07/id_363/LeetCode_191_363.java:39
↓ 2 callers
Method
helper
(int[] nums)
Week 05/id_388/LeeCode_213_388.java:45
↓ 2 callers
Method
helper
(int [] nums,int lo ,int len)
Week 05/id_693/practise/LeetCode_213_693.java:14
↓ 2 callers
Method
helper
(int[] nums, int start, int end)
Week 05/id_363/practice/LeetCode_213_363.java:39
↓ 2 callers
Method
helper
(self, s, l, r)
Week 08/id_433/LeetCode_5_433.py:14
↓ 2 callers
Function
index
(nums []int, num float64)
Week 07/id_733/LeetCode_493_733.go:57
↓ 2 callers
Method
inorderTraversal
(TreeNode root)
Week 02/id_443/LeetCode_94_443.java:43
↓ 2 callers
Method
inorderTraversal
(TreeNode root)
Week 02/id_243/LeetCode_94_243.java:15
↓ 2 callers
Method
insert
* Inserts a word into the trie. * @param {string} word * @return {void}
Week 06/id_503/leetcode_208_503.js:13
↓ 2 callers
Method
insert
Inserts a word into the trie.
Week 06/id_613/java/src/main/Trie.java:45
↓ 2 callers
Method
insertFront
Adds an item at the front of Deque. Return true if the operation is successful.
Week 01/id_648/MyCircularDeque.java:18
↓ 2 callers
Method
insertFront
Adds an item at the front of Deque. Return true if the operation is successful.
Week 01/id_418/LeetCode_641_418.java:83
↓ 2 callers
Method
insertFront
Adds an item at the front of Deque. Return true if the operation is successful.
Week 01/id_588/LeetCode_641_588.java:25
↓ 2 callers
Method
insertLast
Adds an item at the rear of Deque. Return true if the operation is successful.
Week 01/id_648/MyCircularDeque.java:27
↓ 2 callers
Method
insertLast
Adds an item at the rear of Deque. Return true if the operation is successful.
Week 01/id_418/LeetCode_641_418.java:172
↓ 2 callers
Method
insertLast
Adds an item at the rear of Deque. Return true if the operation is successful.
Week 01/id_038/week-01-038/src/main/java/com/github/kylefeng/week01/LeetCode_641_038.java:87
↓ 2 callers
Function
isAnagram
(s, t)
Week 02/id_533/LeetCode_242_533.js:9
↓ 2 callers
Method
isAnagram
(String s, String t)
Week 07/id_573/leetcode_242_573.java:1
↓ 2 callers
Method
isAnagram
(String s, String t)
Week 02/id_573/leetcode_242_573.java:1
↓ 2 callers
Method
isAnagram
思路: 可以计算两个字符串中每个字母的出现次数并进行比较,用一个计数器表计算s字母的频率,用t减少计数器表中的每个字母的计数器,然后检查计数器是否回到零
Week 02/id_588/LeetCode_242_588.java:11
↓ 2 callers
Method
isChar
(char ch)
Week 08/id_143/LeetCode_125_143.java:15
↓ 2 callers
Method
isChar
(char ch)
Week 08/id_063/Leetcode_125_063.java:15
↓ 2 callers
Method
isCharOrNum
(char ch)
Week 08/id_143/LeetCode_125_143.java:9
↓ 2 callers
Method
isCharOrNum
(char ch)
Week 08/id_063/Leetcode_125_063.java:9
↓ 2 callers
Method
isEmpty
Checks whether the circular deque is empty or not.
Week 01/id_708/LeetCode_641_708.java:54
↓ 2 callers
Method
isEmpty
Checks whether the circular deque is empty or not.
Week 01/id_653/LeetCode_641_653.java:128
↓ 2 callers
Method
isEmpty
Checks whether the circular deque is empty or not.
Week 01/id_388/LeetCode_641_388.java:97
↓ 2 callers
Method
isEmpty
Checks whether the circular deque is empty or not. */
Week 01/id_508/LeetCode_641_508.cpp:70
↓ 2 callers
Method
isEmpty
Checks whether the circular deque is empty or not.
Week 01/id_038/week-01-038/src/main/java/com/github/kylefeng/week01/LeetCode_641_038.java:162
↓ 2 callers
Method
isEnd
()
Week 06/id_713/LeetCode_212_WordSearchII.java:147
↓ 2 callers
Method
isEnd
()
Week 06/id_558/LeetCode_212_558.java:116
↓ 2 callers
Method
isEnd
()
Week 06/id_698/LeetCode_212_698.java:40
↓ 2 callers
Method
isEnd
()
Week 06/id_143/LeetCode_208_143.java:79
↓ 2 callers
Method
isEndState
(State sta)
Week 06/id_063/Leetcode_773_063.java:55
↓ 2 callers
Method
isFull
是否满仓
Week 01/id_713/ReverseLinkedList.java:215
↓ 2 callers
Method
isFull
()
Week 01/id_618/LeetCode_641_618.java:121
↓ 2 callers
Method
isFull
()
Week 01/id_028/LeetCode_641_028.java:126
↓ 2 callers
Method
isFull
Checks whether the circular deque is full or not.
Week 01/id_648/MyCircularDeque.java:67
↓ 2 callers
Method
isFull
Checks whether the circular deque is full or not.
Week 01/id_708/LeetCode_641_708.java:59
↓ 2 callers
Method
isFull
Checks whether the circular deque is full or not.
Week 01/id_118/LeetCode_641_118.py:85
↓ 2 callers
Method
isFull
Week 01/id_253/LeetCode_641_253.cpp:48
↓ 2 callers
Method
isFull
Checks whether the circular deque is full or not.
Week 01/id_653/LeetCode_641_653.java:139
↓ 2 callers
Method
isFull
()
Week 01/id_308/LeedCode_641.js:52
↓ 2 callers
Method
isFull
Checks whether the circular deque is full or not.
Week 01/id_568/LeetCode_641_568.java:102
↓ 2 callers
Method
isFull
Checks whether the circular deque is full or not.
Week 01/id_658/LeetCode_641_658.java:100
↓ 2 callers
Method
isIand
(int i, int j)
Week 06/id_618/LeetCode_200_618.java:244
↓ 2 callers
Function
isInBoard
(row, col)
Week 03/id_358/leetcode-359-minesweeper.js:75
↓ 2 callers
Method
isIsland
(int i, int j)
Week 06/id_618/LeetCode_200_618.java:52
↓ 2 callers
Method
isIsland
(int i, int j)
Week 06/id_618/LeetCode_200_618.java:105
↓ 2 callers
Function
isLetter
(str byte)
Week 08/id_573/leetcode_917_573.go:23
↓ 2 callers
Method
isMajorElement
(int[] nums, int start, int end, int num)
Week 02/id_063/Java/LeetCode_169_063.java:26
↓ 2 callers
Method
isOkchar
(char c)
Week 08/id_078/LeetCode_917_078.java:66
↓ 2 callers
Function
isPalindrome
(s string, left, right int)
Week 08/id_733/LeetCode_680_733.go:15
↓ 2 callers
Method
isPalindrome
(String s, int start, int end)
Week 08/id_063/Leetcode_680_063.java:11
↓ 2 callers
Function
isPerfectSquare
(num)
Week 03/id_533/LeetCode_367_533.js:8
↓ 2 callers
Method
isPowerOfTwo
(int n)
Week 07/id_613/java/src/main/Leetcode231One.java:5
↓ 2 callers
Method
isPowerOfTwo
(int n)
Week 07/id_613/java/src/main/Leetcode231Two.java:5
↓ 2 callers
Method
isValid
(char[] chars,int i,int j)
Week 08/id_693/LeetCode_680_693.java:31
↓ 2 callers
Method
isValid
(int i, int j, char[][] board)
Week 03/id_063/LeetCode_529_063.java:25
↓ 2 callers
Method
isValidChar
(char c)
Week 08/id_388/LeeCode_388_125.java:64
↓ 2 callers
Method
isVisited
(int i, int j)
Week 06/id_618/LeetCode_200_618.java:56
↓ 2 callers
Method
isVisited
(int i, int j)
Week 06/id_618/LeetCode_200_618.java:109
↓ 2 callers
Function
isWord
(s byte)
Week 08/id_343/LeetCode_917.go:24
↓ 2 callers
Method
kick
(self, prev)
Week 07/id_278/Leetcode_146_278.py:27
↓ 2 callers
Function
ladderLength
(beginWord, endWord, wordList)
Week 03/id_533/LeetCode_127_533.js:10
↓ 2 callers
Method
ladderLength
(String beginWord, String endWord, List<String> wordList)
Week 03/id_038/week-03-038/src/main/java/com/github/kylefeng/LeetCode_127_038.java:16
↓ 2 callers
Method
ladderLength_bfs
BFS:每个单词特殊处理一下:找到词库里面所有编辑距离是1的单词放入到队列中 DFS:找到编辑距离是1的词继续向下dfs @param beginWord @param endWord @param wordList @return
Week 03/id_363/LeetCode_127_363.java:38
↓ 2 callers
Function
lemonadeChange
(bills)
Week 03/id_533/LeetCode_860_533.js:7
↓ 2 callers
Method
lengthOfLIS
(int[] nums)
Week 08/id_693/LeetCode_300_693.java:17
↓ 2 callers
Method
levelOrder
进行层序遍历 @param root @return
Week 02/id_038/week-02-038/src/main/java/com/github/kylefeng/week02/LeetCode_429_038.java:21
↓ 2 callers
Method
longestPalindrome
(String s)
Week 08/id_693/LeetCode_5_693.java:13
↓ 2 callers
Method
longestValidParentheses
(String s)
Week 05/id_573/leetcode_32_573.java:2
↓ 2 callers
Function
lowestCommonAncestor
(root, p, q)
Week 02/id_493/236.二叉树的最近公共祖先.js:21
↓ 2 callers
Method
majorityElement
(self, nums: List[int])
Week 02/id_118/Python/LeetCode_169_118.py:11
↓ 2 callers
Method
majorityElement
1. map 统计数量 时间复杂度是O(n) 2. 排序 记录每个元素的count 时间复杂度是O(nlogn) 3. 分治 4.Booyer-More 算法 候选人 @param nums @return
Week 02/id_363/LeetCode_169_363.java:43
↓ 2 callers
Method
majorityElement2
(int[] nums)
Week 02/id_693/LeetCode_169_693.java:23
↓ 2 callers
Method
majorityElement2Better
数据排序后,众数因为占数据的一般以上,所以下标在len / 2位置的数字一定是众数 如果众数是数组的最小值或者最大值,当数组数量是奇数/偶数,那么n/2 一定会覆盖到 @param nums @return
Week 02/id_363/LeetCode_169_363.java:81
↓ 2 callers
Method
majorityElement3DivideAndConquer
(int[] nums)
Week 02/id_363/LeetCode_169_363.java:87
← previous
next →
501–600 of 7,451, ranked by callers