數學・組合 Math / Combinatorics
55 題(20 題以此為主技法)
🎯 何時用
數論、幾何、計數、博弈,常有 O(1)/O(log n) 公式。
🧩 模板心法
找規律或公式:GCD/快速冪、組合數、Catalan、模運算、博弈的必勝態。
Easy 19 題
- #9Palindrome Number
- #66Plus One
- #168Excel Sheet Column Title
- #263Ugly Number
- #1071Greatest Common Divisor of Strings
- #1260Shift 2D Grid
- #1523Count Odd Numbers in an Interval Range
- #1572Matrix Diagonal Sum
- #1822Sign of An Array
- #70Climbing Stairs
- #268Missing Number
- #202Happy Number
- #13Roman to Integer
- #67Add Binary
- #69Sqrt(x)
- #367Valid Perfect Square
- #441Arranging Coins
- #989Add to Array-Form of Integer
- #1137N-th Tribonacci Number
Medium 30 題
- #48Rotate Image
- #54Spiral Matrix
- #73Set Matrix Zeroes
- #43Multiply Strings
- #50Pow(x, n)
- #6Zigzag Conversion
- #8String to Integer (atoi)
- #59Spiral Matrix II
- #1041Robot Bounded In Circle
- #2028Find Missing Observations
- #2348Number of Zero-Filled Subarrays
- #62Unique Paths
- #371Sum of Two Integers
- #2Add Two Numbers
- #150Evaluate Reverse Polish Notation
- #227Basic Calculator II
- #7Reverse Integer
- #12Integer to Roman
- #29Divide Two Integers
- #96Unique Binary Search Trees
- #189Rotate Array
- #279Perfect Squares
- #343Integer Break
- #523Continuous Subarray Sum
- #528Random Pick with Weight
- #877Stone Game
- #1140Stone Game II
- #1498Number of Subsequences That Satisfy The Given Sum Condition
- #2001Number of Pairs of Interchangeable Rectangles
- #2013Detect Squares