Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/austingebauer/go-leetcode
/ functions
Functions
430 in github.com/austingebauer/go-leetcode
⨍
Functions
430
◇
Types & classes
142
Function
buildTree0
Initial solution, which was off. Mostly prototyping around incomplete idea.
construct_binary_tree_from_preorder_and_inorder_traversal_105/solution.go:57
Function
buildTree1
First attempt, getting closer, but still didn't see key to unlock solving the problem.
construct_binary_tree_from_preorder_and_inorder_traversal_105/solution.go:30
Function
characterReplacement0
Note: Close but incorrect
longest_repeating_character_replacement_424/solution.go:95
Function
characterReplacement1
Really close, but too slow.
longest_repeating_character_replacement_424/solution.go:30
Function
coinChangeBottomUp1
Version 2: Bottom-up approach using MaxInt32 for min comparison
coin_change_322/solution.go:42
Function
coinChangeTopDown
Version 1: Top-down approach using recursion
coin_change_322/solution.go:72
Function
eraseOverlapIntervals0
Initial solution, which failed to recognize that the removal order isn't necessarily a part of the start sorted sequence.
non_overlapping_intervals_435/solution.go:86
Function
eraseOverlapIntervals1
Second solution, which is correct but time limit exceeded.
non_overlapping_intervals_435/solution.go:45
Function
explore1
This approach is slow (exponential runtime). It works, but times out on leetcode. We can do better.
longest_increasing_subsequence_300/solution.go:99
Function
explore2
This approach is also slow (O(2^n) runtime. It works, but times out on leetcode. We can do better.
longest_increasing_subsequence_300/solution.go:82
Function
groupAnagrams0
Note: Wrong approach. Good lessons though!
group_anagrams_49/solution.go:72
Function
groupAnagrams1
Second solution based on sorting the strings
group_anagrams_49/solution.go:42
Function
insert0
Note: good attempt with 152 / 154 test cases passed. This got messy. Tried to merge newInterval into intervals. Can do better!
insert_interval_57/solution.go:82
Function
isSymmetricWrong
Based on in-order traversal being a palindrome. Wrong approach but good lesson on array appending in recursive function.
symmetric_tree_101/solution.go:39
Function
lengthOfLISOther
(nums []int)
longest_increasing_subsequence_300/solution.go:35
Function
levelOrder0
Note: study again.
binary_tree_level_order_traversal_102/solution.go:45
Function
longestCommonSubsequence1
Note: first attempt that passed test cases in description examples. Isn't correct in all cases.
longest_common_subsequence_1143/solution.go:80
Function
maxProduct0
First, O(n^2) solution.
maximum_product_subarray_152/solution.go:29
Function
merge0
First solution
merge_intervals_56/solution.go:38
Function
merge0
Note: original solution with array shifting
merge_sorted_array_88/solution.go:56
Function
merge2
Note: solution from rotate_string_796 interview that stumped me for a bit. Wanted to solve without shifting and was tricky.
merge_sorted_array_88/solution.go:24
Function
mergeTwoLists1
(l1 *ListNode, l2 *ListNode)
merge_two_sorted_lists_21/solution.go:32
Function
minWindow0
Initial solution. Pretty close, but overly complicated and assumed that duplicates of t were not allowed, meaning the substring of s must have exactly
minimum_window_substring_76/solution.go:59
Function
moveZeroes2
(nums []int)
move_zeroes_283/solution.go:19
Function
reverseList1
Reverses the passed list without creating a new list by prepending front nodes to the end.
reverse_linked_list_206/solution.go:34
Function
reverseStrOrig
Note: original solution from mock interview. I learned how to reverse string in place by using []rune or []byte. Having to reverse by string concatena
reverse_string_ii_541/solution.go:32
Function
search0
Note: Study again
search_in_rotated_sorted_array_33/solution.go:77
Function
setZeroes1
Note: this was accepted into leetcode and uses O(1) space. There is a different solution that was hinted at that works better with ALL input. This alg
set_matrix_zeros_73/solution.go:65
Function
threeSum0
(nums []int)
three_sum_15/solution.go:50
Function
twoSumSortedInput
twoSumSortedInput assumes that nums is sorted.
two_sum_1/solution.go:25
← previous
401–430 of 430, ranked by callers