随笔分类 -  LeetCode(Java)

1 2 3 4 5 ··· 12 下一页
摘要:LeetCode 1408. String Matching in an Array (数组中的字符串匹配) 题目 链接 https://leetcode.cn/problems/string-matching-in-an-array/ 问题描述 给你一个字符串数组 words ,数组中的每个字符串 阅读全文
posted @ 2022-08-06 10:10 cheng102e 阅读(46) 评论(0) 推荐(0) 编辑
摘要:LeetCode 518. Coin Change 2 (零钱兑换 II) 题目 链接 https://leetcode.cn/problems/coin-change-2/ 问题描述 给你一个整数数组 coins 表示不同面额的硬币,另给一个整数 amount 表示总金额。 请你计算并返回可以凑成 阅读全文
posted @ 2022-07-01 16:53 cheng102e 阅读(26) 评论(0) 推荐(0) 编辑
摘要:LeetCode 494. Target Sum (目标和) 题目 链接 https://leetcode.cn/problems/target-sum/ 问题描述 给你一个整数数组 nums 和一个整数 target 。 向数组中的每个整数前添加 '+' 或 '-' ,然后串联起所有整数,可以构造 阅读全文
posted @ 2022-06-30 16:45 cheng102e 阅读(58) 评论(0) 推荐(0) 编辑
摘要:LeetCode 1049. Last Stone Weight II (最后一块石头的重量 II) 题目 链接 https://leetcode.cn/problems/last-stone-weight-ii/ 问题描述 有一堆石头,用整数数组 stones 表示。其中 stones[i] 表示 阅读全文
posted @ 2022-06-30 15:25 cheng102e 阅读(41) 评论(0) 推荐(0) 编辑
摘要:LeetCode 416. Partition Equal Subset Sum (分割等和子集) 题目 链接 https://leetcode.cn/problems/partition-equal-subset-sum/ 问题描述 给你一个 只包含正整数 的 非空 数组 nums 。请你判断是否 阅读全文
posted @ 2022-06-29 11:36 cheng102e 阅读(23) 评论(0) 推荐(0) 编辑
摘要:LeetCode 96. Unique Binary Search Trees (不同的二叉搜索树) 题目 链接 https://leetcode.cn/problems/unique-binary-search-trees/ 问题描述 给你一个整数 n ,求恰由 n 个节点组成且节点值从 1 到 阅读全文
posted @ 2022-06-28 22:19 cheng102e 阅读(20) 评论(0) 推荐(0) 编辑
摘要:LeetCode 343. Integer Break (整数拆分) 题目 链接 https://leetcode.cn/problems/integer-break/ 问题描述 给定一个正整数 n ,将其拆分为 k 个 正整数 的和( k >= 2 ),并使这些整数的乘积最大化。 返回 你可以获得 阅读全文
posted @ 2022-06-28 22:10 cheng102e 阅读(25) 评论(0) 推荐(0) 编辑
摘要:LeetCode 56. Merge Intervals (合并区间) 题目 链接 https://leetcode.cn/problems/merge-intervals/ 问题描述 以数组 intervals 表示若干个区间的集合,其中单个区间为 intervals[i] = [starti, 阅读全文
posted @ 2022-06-28 20:10 cheng102e 阅读(24) 评论(0) 推荐(0) 编辑
摘要:LeetCode 738. Monotone Increasing Digits (单调递增的数字) 题目 链接 https://leetcode.cn/problems/monotone-increasing-digits/ 问题描述 当且仅当每个相邻位数上的数字 x 和 y 满足 x <= y  阅读全文
posted @ 2022-06-28 17:20 cheng102e 阅读(24) 评论(0) 推荐(0) 编辑
摘要:title: date: 2022-06-28 16:23:00 tags: categories: LeetCode LeetCode 763. Partition Labels (划分字母区间) 题目 链接 https://leetcode.cn/problems/partition-label 阅读全文
posted @ 2022-06-28 16:35 cheng102e 阅读(26) 评论(0) 推荐(0) 编辑
摘要:LeetCode 435. Non-overlapping Intervals (无重叠区间) 题目 链接 https://leetcode.cn/problems/non-overlapping-intervals/ 问题描述 给定一个区间的集合 intervals ,其中 intervals[i 阅读全文
posted @ 2022-06-27 22:24 cheng102e 阅读(24) 评论(0) 推荐(0) 编辑
摘要:LeetCode 452. Minimum Number of Arrows to Burst Balloons (用最少数量的箭引爆气球) 题目 链接 https://leetcode.cn/problems/minimum-number-of-arrows-to-burst-balloons/ 阅读全文
posted @ 2022-06-27 20:48 cheng102e 阅读(33) 评论(0) 推荐(0) 编辑
摘要:LeetCode 860. Lemonade Change (柠檬水找零) 题目 链接 https://leetcode.cn/problems/lemonade-change/ 问题描述 在柠檬水摊上,每一杯柠檬水的售价为 5 美元。顾客排队购买你的产品,(按账单 bills 支付的顺序)一次购买 阅读全文
posted @ 2022-06-23 10:44 cheng102e 阅读(26) 评论(0) 推荐(0) 编辑
摘要:LeetCode 134. Gas Station (加油站) 题目 链接 https://leetcode.cn/problems/gas-station/ 问题描述 在一条环路上有 n 个加油站,其中第 i 个加油站有汽油 gas[i] 升。 你有一辆油箱容量无限的的汽车,从第 i 个加油站开往 阅读全文
posted @ 2022-06-23 10:43 cheng102e 阅读(29) 评论(0) 推荐(0) 编辑
摘要:LeetCode 406. Queue Reconstruction by Height (根据身高重建队列) 题目 链接 https://leetcode.cn/problems/queue-reconstruction-by-height/ 问题描述 假设有打乱顺序的一群人站成一个队列,数组 p 阅读全文
posted @ 2022-06-23 10:41 cheng102e 阅读(18) 评论(0) 推荐(0) 编辑
摘要:LeetCode 135. Candy (分发糖果) 题目 链接 https://leetcode.cn/problems/candy/ 问题描述 n 个孩子站成一排。给你一个整数数组 ratings 表示每个孩子的评分。 你需要按照以下要求,给这些孩子分发糖果: 每个孩子至少分配到 1 个糖果。 阅读全文
posted @ 2022-06-22 16:21 cheng102e 阅读(24) 评论(0) 推荐(0) 编辑
摘要:LeetCode 1005. Maximize Sum Of Array After K Negations (K 次取反后最大化的数组和) 题目 链接 https://leetcode.cn/problems/maximize-sum-of-array-after-k-negations/ 问题描 阅读全文
posted @ 2022-06-21 16:38 cheng102e 阅读(24) 评论(0) 推荐(0) 编辑
摘要:LeetCode 45. Jump Game II (跳跃游戏 II) 题目 链接 https://leetcode.cn/problems/jump-game-ii/ 问题描述 给你一个非负整数数组 nums ,你最初位于数组的第一个位置。 数组中的每个元素代表你在该位置可以跳跃的最大长度。 你的 阅读全文
posted @ 2022-06-20 16:41 cheng102e 阅读(25) 评论(0) 推荐(0) 编辑
摘要:LeetCode 55. Jump Game (跳跃游戏) 题目 链接 https://leetcode.cn/problems/jump-game/ 问题描述 给定一个非负整数数组 nums ,你最初位于数组的 第一个下标 。 数组中的每个元素代表你在该位置可以跳跃的最大长度。 判断你是否能够到达 阅读全文
posted @ 2022-06-20 15:44 cheng102e 阅读(18) 评论(0) 推荐(0) 编辑
摘要:LeetCode 376. Wiggle Subsequence (摆动序列) 题目 链接 https://leetcode.cn/problems/wiggle-subsequence/ 问题描述 如果连续数字之间的差严格地在正数和负数之间交替,则数字序列称为 摆动序列 。第一个差(如果存在的话) 阅读全文
posted @ 2022-06-20 15:21 cheng102e 阅读(20) 评论(0) 推荐(0) 编辑

1 2 3 4 5 ··· 12 下一页
点击右上角即可分享
微信分享提示