Balanced Binary Tree 這題要求判斷一個二元樹是否為「平衡的」,即每個節點的左右子樹的高度差不能超過 1。
題目:
給定一個二元樹,判斷它是否...
961. N-Repeated Element in Size 2N Array
tags: Easy、Sizeof
You are given an int...
本文大綱
引言
LeetCode 介紹
Python 複習
list(列表)與string(字串)的切片
generator 與 list comprehe...
20. Valid Parentheses
題目描述:
給定一個只包含 '('、')'、'{'、'}'、'[' 和 ']' 的字符串 s,判斷字符串是否有效。...
What is Endianness?
Endianness(位元組序)是指多位元組資料在計算機記憶體中儲存的順序。資料的表示通常涉及多個位元組,尤其是當處理整...
HardRelated Topics: Graph / Heap (Priority Queue) / Shortest PathLeetCode Sourc...