leetcode.cn 2026-03-27
🟢2946.matrix-similarity-after-cyclic-shifts
🏷️ Tags
#array #math #matrix #simulation
🟢2946.matrix-similarity-after-cyclic-shifts
🏷️ Tags
#array #math #matrix #simulation
Telegraph
matrix-similarity-after-cyclic-shifts
给你一个下标从 0 开始且大小为 m x n 的整数矩阵 mat 和一个整数 k 。请你将矩阵中的 奇数 行循环 右 移 k 次,偶数 行循环 左 移 k 次。 如果初始矩阵和最终矩阵完全相同,则返回 true ,否则返回 false 。 示例 1: 输入:mat = [[1,2,1,2],[5,5,5,5],[6,3,6,3]], k = 2 输出:true 解释: 初始矩阵如图一所示。 图二表示对奇数行右移一次且对偶数行左移一次后的矩阵状态。 图三是经过两次循环移位后的最终矩阵状态,与初始矩阵相同。…
leetcode.com 2026-03-27
🟢2946.matrix-similarity-after-cyclic-shifts
🏷️ Tags
#array #math #matrix #simulation
🟢2946.matrix-similarity-after-cyclic-shifts
🏷️ Tags
#array #math #matrix #simulation
Telegraph
matrix-similarity-after-cyclic-shifts
You are given an m x n integer matrix mat and an integer k. The matrix rows are 0-indexed. The following proccess happens k times:
leetcode.cn 2026-03-28
🔴2573.find-the-string-with-lcp
🏷️ Tags
#greedy #union_find #array #string #dynamic_programming #matrix
🔴2573.find-the-string-with-lcp
🏷️ Tags
#greedy #union_find #array #string #dynamic_programming #matrix
Telegraph
find-the-string-with-lcp
对任一由 n 个小写英文字母组成的字符串 word ,我们可以定义一个 n x n 的矩阵,并满足:
leetcode.cn 2026-03-30
🟡2840.check-if-strings-can-be-made-equal-with-operations-ii
🏷️ Tags
#hash_table #string #sorting
🟡2840.check-if-strings-can-be-made-equal-with-operations-ii
🏷️ Tags
#hash_table #string #sorting
Telegraph
check-if-strings-can-be-made-equal-with-operations-ii
给你两个字符串 s1 和 s2 ,两个字符串长度都为 n ,且只包含 小写 英文字母。 你可以对两个字符串中的 任意一个 执行以下操作 任意 次:
leetcode.com 2026-03-30
🟡2840.check-if-strings-can-be-made-equal-with-operations-ii
🏷️ Tags
#hash_table #string #sorting
🟡2840.check-if-strings-can-be-made-equal-with-operations-ii
🏷️ Tags
#hash_table #string #sorting
Telegraph
check-if-strings-can-be-made-equal-with-operations-ii
You are given two strings s1 and s2, both of length n, consisting of lowercase English letters. You can apply the following operation on any of the two strings any number of times:
leetcode.cn 2026-03-31
🔴3474.lexicographically-smallest-generated-string
🏷️ Tags
#greedy #string #string_matching
🔴3474.lexicographically-smallest-generated-string
🏷️ Tags
#greedy #string #string_matching
Telegraph
lexicographically-smallest-generated-string
给你两个字符串,str1 和 str2,其长度分别为 n 和 m 。
leetcode.com 2026-03-31
🔴3474.lexicographically-smallest-generated-string
🏷️ Tags
#greedy #string #string_matching
🔴3474.lexicographically-smallest-generated-string
🏷️ Tags
#greedy #string #string_matching
Telegraph
lexicographically-smallest-generated-string
You are given two strings, str1 and str2, of lengths n and m, respectively. A string word of length n + m - 1 is defined to be generated by str1 and str2 if it satisfies the following conditions for each index 0 <= i <= n - 1:
leetcode.cn 2026-04-02
🟡3418.maximum-amount-of-money-robot-can-earn
🏷️ Tags
#array #dynamic_programming #matrix
🟡3418.maximum-amount-of-money-robot-can-earn
🏷️ Tags
#array #dynamic_programming #matrix
Telegraph
maximum-amount-of-money-robot-can-earn
给你一个 m x n 的网格。一个机器人从网格的左上角 (0, 0) 出发,目标是到达网格的右下角 (m - 1, n - 1)。在任意时刻,机器人只能向右或向下移动。 网格中的每个单元格包含一个值 coins[i][j]:
leetcode.com 2026-04-02
🟡3418.maximum-amount-of-money-robot-can-earn
🏷️ Tags
#array #dynamic_programming #matrix
🟡3418.maximum-amount-of-money-robot-can-earn
🏷️ Tags
#array #dynamic_programming #matrix
Telegraph
maximum-amount-of-money-robot-can-earn
You are given an m x n grid. A robot starts at the top-left corner of the grid (0, 0) and wants to reach the bottom-right corner (m - 1, n - 1). The robot can move either right or down at any point in time. The grid contains a value coins[i][j] in each cell:
leetcode.cn 2026-04-03
🔴3661.maximum-walls-destroyed-by-robots
🏷️ Tags
#array #binary_search #dynamic_programming #sorting
🔴3661.maximum-walls-destroyed-by-robots
🏷️ Tags
#array #binary_search #dynamic_programming #sorting
Telegraph
maximum-walls-destroyed-by-robots
robots[i] 是第 i 个机器人的位置。
leetcode.com 2026-04-03
🔴3661.maximum-walls-destroyed-by-robots
🏷️ Tags
#array #binary_search #dynamic_programming #sorting
🔴3661.maximum-walls-destroyed-by-robots
🏷️ Tags
#array #binary_search #dynamic_programming #sorting
Telegraph
maximum-walls-destroyed-by-robots
robots[i] is the position of the ith robot.