面试场景
高频考察问题建模、边界条件与口头表达的清晰度。
常见误区
只背模板不解释为什么,容易在追问里失分。
练习策略
每轮练 3-5 题,固定复盘复杂度和可替代解法。
推荐练习顺序
题库
位掩码 题库
先展示一段最适合快速浏览的题目列表,继续滚动时再慢慢续载,避免专题页被长列表一下子拉穿。
慢加载专题题库
适合这类题很多的专题,先扫结构,再逐步深入。
当前展示 24 / 47 道题目
每次续载 24 题我能赢吗
Determine if the first player can guarantee a win in a turn-based number selection game using state transition dynamic p…
火柴拼正方形
The problem asks to determine if we can use matchsticks to form a square, exploring dynamic programming and backtracking…
优美的排列
The Beautiful Arrangement problem asks for the number of valid permutations of n integers satisfying specific divisibili…
大礼包
Minimize the cost of purchasing items using available special offers with state transition dynamic programming.
贴纸拼词
Determine the minimum number of stickers needed to spell a target word using array scanning and hash lookups for efficie…
划分为k个相等的子集
Determine if an integer array can be partitioned into k subsets where each subset sums to the same value using DP and ba…
数组的均值分割
Determine whether an integer array can be partitioned into two non-empty subarrays with the same average using dynamic p…
访问所有节点的最短路径
Solve the Shortest Path Visiting All Nodes problem by exploring dynamic programming, bit manipulation, and breadth-first…
最短超级串
This problem requires constructing the shortest string containing all input words using state transition dynamic program…
平方数组的数目
Count the number of squareful arrays from the given list of integers by checking adjacent pairs' sums for perfect square…
最小的必要团队
Find the smallest subset of people covering all required skills using bitmask dynamic programming for efficient state tr…
得分最高的单词集合
Calculate the highest total score by selecting words from a list using available letters, respecting individual letter s…
参加考试的最大学生数
Calculate the maximum number of students who can take an exam without cheating using state transition dynamic programmin…
每个人戴不同帽子的方案数
Calculate all unique assignments of hats to people using state transition dynamic programming with bitmasking for collis…
并行课程 II
Determine the minimum semesters to complete all courses with prerequisites using state transition dynamic programming an…
连通两组点的最小成本
Compute the minimum cost to fully connect two groups of points using dynamic programming and bitmasking efficiently.
统计子树中城市之间最大距离
This problem asks you to count subtrees in a tree structure where the maximum distance between any two cities matches sp…
分配重复整数
Determine if you can allocate integers to satisfy customer quantities using state transition dynamic programming techniq…
最大化网格幸福感
Maximize Grid Happiness is a dynamic programming problem focusing on state transitions with bitmasking to maximize happi…
最小不兼容性
Optimize the sum of incompatibilities when distributing an array into subsets with unique elements.
完成所有工作的最短时间
Minimize the maximum working time of k workers by optimally assigning jobs, leveraging dynamic programming and bit manip…
最接近目标值的子序列和
Find the minimum absolute difference between a target goal and any subsequence sum using optimized dynamic programming a…
N 次操作后的最大分数和
Maximize the score after n operations by selecting pairs from the array and using their GCD with dynamic programming or …
得到新鲜甜甜圈的最多组数
Reorder groups to maximize happy customers by using state transition dynamic programming with bitmasking for optimal bat…
swap_vert在题库框内继续向下滚动,也会自动续载