Kth Largest Element in an Array
LC 215 題意
(Heap / Quickselect)
給定一個整數陣列 nums 和一...
Lowest Common Ancestor of a Binary Search Tree
thoughts
BST 性質:左子樹 < root &l...
543 Diameter of Binary Tree
thoughts
樹的直徑:任意兩個節點之間的最長路徑(經過 root 或不經 root)。
DFS...
Find Peak Element (LeetCode 162, Binary Search)
thoughts
峰值定義:nums[i] > nums...
Middle of the Linked List (Linked List) 876
question
給定一個單向鏈結串列,找到其中間節點並回傳。
如果有...
嗨嗨各位晚安,歡迎來到coding小白盜版學校官網的第15天!這個計畫的內容是我這個coding超新手會在這30天裡,把複刻學校官網當作目標,從最基礎的前端ht...