小无编辑摘要 |
小无编辑摘要 |
||
| (未显示同一用户的2个中间版本) | |||
| 第8行: | 第8行: | ||
</math> | </math> | ||
just get the substring of gcd length | just get the substring of gcd length | ||
* 1431. Kids With the Greatest Number of Candies: find the max value first | |||
* 605. Can Place Flowers: check neighbours | |||
* 345. Reverse Vowels of a String: exchange local array | |||
* 151. Reverse Words in a String: split and then concat/ reverse array | |||
* 238. Product of Array Except Self: p = p_left * p_right | |||
* 334. Increasing Triplet Subsequence: tracking the smallest, the second smallest num | |||
2026年3月25日 (三) 01:44的最新版本
Array/String:
- 1768. Merge Strings Alternately: use StringBuilder
- 1071. Greatest Common Divisor of Strings: if str1 and str2 can be divided, then
[math]\displaystyle{ str1 + str2 = str2 + str1 \gcd(a,b)=\gcd(b,a \bmod b) }[/math] just get the substring of gcd length
- 1431. Kids With the Greatest Number of Candies: find the max value first
- 605. Can Place Flowers: check neighbours
- 345. Reverse Vowels of a String: exchange local array
- 151. Reverse Words in a String: split and then concat/ reverse array
- 238. Product of Array Except Self: p = p_left * p_right
- 334. Increasing Triplet Subsequence: tracking the smallest, the second smallest num