226. Invert Binary Tree
題目描述得非常簡單,給定一棵二元樹,你需要翻轉它,將左子樹與右子樹互換,輸出這棵樹翻轉後的結果。使用遞迴的解法:...
A sentence consists of lowercase letters ('a' to 'z'), digits ('0' to '9'), hyph...
DAY 8 試題
問題描述
給定一個整數陣列 height,每個值代表對應位置上的垂直線高度,這些垂直線與 x 軸形成容器。請找到兩條垂直線,與 x 軸組成一...
Given a 0-indexed integer array nums of size n, find the maximum difference betw...
Problem :
Given the root of a binary tree, imagine yourself standing on the righ...
題目要我在它給的整數組 nums 裡找三個數,讓它們的和最接近目標值 target,且保證每個輸入都有唯一解,這種題目通常要考慮很多不同的組合來找到最完美的結果...