Skip to content

LeetCode Wiki Contributions

🎠 SkyHorse Rideshare

After establishing SkyHorse in May 2026, which contains my O(n)O(n) double stacks method for LeetCode No.2454, I suddenly remembered that, in November 2024, I actually already posted the same method in the Discussions section of a public repo.

🧘🏻‍♀️ Active Sharing Mindset

LeetCode Wiki has activity and size that let me realize: “why not share some different style AC methods into public community?”

Coincidentally, I found myself having some hard problems’ solutions which weren’t in LeetCode Wiki at that time, so everything started at elevating solution of No.2454 from Discussions into PR.

In one month, I had 8 solution code & tutorials merged into LeetCode Wiki.

My Merged PRs Compared To LeetCode Wiki Original Solutions

Efficiency Enhancement: 3

No.2454 Next Greater Element IV: achieved O(n)O(n) time by double stacks, reducing from global sorting and ordered set of O(nlogn)O(nlogn) time.

No.3430 Maximum and Minimum Sums of at Most Size K Subarrays: delivered the repo’s first tutorial for No.3430, achieving both time and space complexities at O(n)O(n) via deques.

No.1793 Maximum Score of a Good Subarray: optimized O(1)O(1) space with greedy two pointers, reducing from stack’s O(n)O(n) space.

Different Style Same Efficiency: 4

No.768 Max Chunks To Make Sorted II: wrote O(n)O(n) time method by prefix max & suffix min, complementing original solution of O(n)O(n) stack.

No.315 Count of Smaller Numbers After Self: provided O(nlogn)O(nlogn) time answer by merge sort, offering a more implementation-friendly data structure to complement original solutions’ O(nlogn)O(nlogn) segment tree and Fenwick tree.

No.2736. Maximum Sum Queries: gave O(nlogn)O(nlogn) time complexity with sorting, stack and binary search, complementing original solution’s O(nlogn)O(nlogn) Fenwick tree.

No.987. Vertical Order Traversal of a Binary Tree: submitted O(nlogn)O(nlogn) time answer of BFS + sorting, avoiding recursions while complementing original solution’s O(nlogn)O(nlogn) DFS + sorting.

‍😁️ Still Prefer SkyHorse

Because there aren’t any wording formats to follow. Styles in SkyHorse are more entertaining~~