leetcode.cn 2026-01-19
🟡1292.maximum-side-length-of-a-square-with-sum-less-than-or-equal-to-threshold
🏷️ Tags
#array #binary_search #matrix #prefix_sum
🟡1292.maximum-side-length-of-a-square-with-sum-less-than-or-equal-to-threshold
🏷️ Tags
#array #binary_search #matrix #prefix_sum
Telegraph
maximum-side-length-of-a-square-with-sum-less-than-or-equal-to-threshold
给你一个大小为 m x n 的矩阵 mat 和一个整数阈值 threshold。 请你返回元素总和小于或等于阈值的正方形区域的最大边长;如果没有这样的正方形区域,则返回 0 。 示例 1: 输入:mat = [[1,1,3,2,4,3,2],[1,1,3,2,4,3,2],[1,1,3,2,4,3,2]], threshold = 4 输出:2 解释:总和小于或等于 4 的正方形的最大边长为 2,如图所示。 示例 2: 输入:mat = [[2,2,2,2,2],[2,2,2,2,2],[2,2,2,2…
leetcode.com 2026-01-19
🟡1292.maximum-side-length-of-a-square-with-sum-less-than-or-equal-to-threshold
🏷️ Tags
#array #binary_search #matrix #prefix_sum
🟡1292.maximum-side-length-of-a-square-with-sum-less-than-or-equal-to-threshold
🏷️ Tags
#array #binary_search #matrix #prefix_sum
Telegraph
maximum-side-length-of-a-square-with-sum-less-than-or-equal-to-threshold
Given a m x n matrix mat and an integer threshold, return the maximum side-length of a square with a sum less than or equal to threshold or return 0 if there is no such square. Example 1: Input: mat = [[1,1,3,2,4,3,2],[1,1,3,2,4,3,2],[1,1,3,2,4,3,2]], threshold…
leetcode.cn 2026-01-22
🟢3507.minimum-pair-removal-to-sort-array-i
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
🟢3507.minimum-pair-removal-to-sort-array-i
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
Telegraph
minimum-pair-removal-to-sort-array-i
给你一个数组 nums,你可以执行以下操作任意次数:
leetcode.com 2026-01-22
🟢3507.minimum-pair-removal-to-sort-array-i
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
🟢3507.minimum-pair-removal-to-sort-array-i
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
Telegraph
minimum-pair-removal-to-sort-array-i
Given an array nums, you can perform the following operation any number of times:
leetcode.cn 2026-01-23
🔴3510.minimum-pair-removal-to-sort-array-ii
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
🔴3510.minimum-pair-removal-to-sort-array-ii
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
Telegraph
minimum-pair-removal-to-sort-array-ii
给你一个数组 nums,你可以执行以下操作任意次数:
leetcode.com 2026-01-23
🔴3510.minimum-pair-removal-to-sort-array-ii
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
🔴3510.minimum-pair-removal-to-sort-array-ii
🏷️ Tags
#array #hash_table #linked_list #doubly_linked_list #ordered_set #simulation #heap_priority_queue
Telegraph
minimum-pair-removal-to-sort-array-ii
Given an array nums, you can perform the following operation any number of times:
leetcode.cn 2026-01-24
🟡1877.minimize-maximum-pair-sum-in-array
🏷️ Tags
#greedy #array #two_pointers #sorting
🟡1877.minimize-maximum-pair-sum-in-array
🏷️ Tags
#greedy #array #two_pointers #sorting
Telegraph
minimize-maximum-pair-sum-in-array
一个数对 (a,b) 的 数对和 等于 a + b 。最大数对和 是一个数对数组中最大的 数对和 。
leetcode.com 2026-01-24
🟡1877.minimize-maximum-pair-sum-in-array
🏷️ Tags
#greedy #array #two_pointers #sorting
🟡1877.minimize-maximum-pair-sum-in-array
🏷️ Tags
#greedy #array #two_pointers #sorting
Telegraph
minimize-maximum-pair-sum-in-array
The pair sum of a pair (a,b) is equal to a + b. The maximum pair sum is the largest pair sum in a list of pairs.
leetcode.cn 2026-01-25
🟢1984.minimum-difference-between-highest-and-lowest-of-k-scores
🏷️ Tags
#array #sorting #sliding_window
🟢1984.minimum-difference-between-highest-and-lowest-of-k-scores
🏷️ Tags
#array #sorting #sliding_window
Telegraph
minimum-difference-between-highest-and-lowest-of-k-scores
给你一个 下标从 0 开始 的整数数组 nums ,其中 nums[i] 表示第 i 名学生的分数。另给你一个整数 k 。 从数组中选出任意 k 名学生的分数,使这 k 个分数间 最高分 和 最低分 的 差值 达到 最小化 。 返回可能的 最小差值 。 示例 1: 输入:nums = [90], k = 1 输出:0 解释:选出 1 名学生的分数,仅有 1 种方法: - [90] 最高分和最低分之间的差值是 90 - 90 = 0 可能的最小差值是 0 示例 2: 输入:nums = [9,4,1,7]…
leetcode.com 2026-01-25
🟢1984.minimum-difference-between-highest-and-lowest-of-k-scores
🏷️ Tags
#array #sorting #sliding_window
🟢1984.minimum-difference-between-highest-and-lowest-of-k-scores
🏷️ Tags
#array #sorting #sliding_window
Telegraph
minimum-difference-between-highest-and-lowest-of-k-scores
You are given a 0-indexed integer array nums, where nums[i] represents the score of the ith student. You are also given an integer k. Pick the scores of any k students from the array so that the difference between the highest and the lowest of the k scores…
leetcode.cn 2026-01-27
🟡3650.minimum-cost-path-with-edge-reversals
🏷️ Tags
#graph #shortest_path #heap_priority_queue
🟡3650.minimum-cost-path-with-edge-reversals
🏷️ Tags
#graph #shortest_path #heap_priority_queue
Telegraph
minimum-cost-path-with-edge-reversals
给你一个包含 n 个节点的有向带权图,节点编号从 0 到 n - 1。同时给你一个数组 edges,其中 edges[i] = [ui, vi, wi] 表示一条从节点 ui 到节点 vi 的有向边,其成本为 wi。
leetcode.com 2026-01-27
🟡3650.minimum-cost-path-with-edge-reversals
🏷️ Tags
#graph #shortest_path #heap_priority_queue
🟡3650.minimum-cost-path-with-edge-reversals
🏷️ Tags
#graph #shortest_path #heap_priority_queue
Telegraph
minimum-cost-path-with-edge-reversals
You are given a directed, weighted graph with n nodes labeled from 0 to n - 1, and an array edges where edges[i] = [ui, vi, wi] represents a directed edge from node ui to node vi with cost wi. Each node ui has a switch that can be used at most once: when…