今天我們繼續看一題字串類型的題目:拆字。
🟨拆字
本題取自 Leetcode 139. Word Break
題目
Given a string s and a...
226. Invert Binary Tree
題目描述得非常簡單,給定一棵二元樹,你需要翻轉它,將左子樹與右子樹互換,輸出這棵樹翻轉後的結果。使用遞迴的解法:...
Given an array of points where points[i] = [xᵢ, yᵢ] represents a point on the X...
A sentence consists of lowercase letters ('a' to 'z'), digits ('0' to '9'), hyph...
DAY 9 試題
問題描述
給定一個字串 s 和一個字典 wordDict,其中字典包含多個單詞。請判斷字串 s 是否能夠被分割為一組以空格分隔的字典單詞序列...
Problem :
Given the root of a binary tree, imagine yourself standing on the righ...