[LeetCode]Minimum ASCII Delete Sum for Two Strings

题目描述:

LeetCode 712. Minimum ASCII Delete Sum for Two Strings

Given two strings s1, s2, find the lowest ASCII sum of deleted characters to make two strings equal.

Example 1:

Input: s1 = "sea", s2 = "eat"
Output: 231
Explanation: Deleting "s" ...

继续阅读

[LeetCode]Best Time to Buy and Sell Stock with Transaction Fee

题目描述:

LeetCode 714. Best Time to Buy and Sell Stock with Transaction Fee

Your are given an array of integers prices, for which the i-th element is the price of a given stock on day i; and a non-negative ...

继续阅读

LeetCode Weekly Contest 54解题报告

LeetCode Weekly Contest 54是LeetCode举办的第五十八场正式周赛,共4道题目,比赛时长1.5小时。

比赛链接:https://leetcode.com/contest/leetcode-weekly-contest-54/

题解列表:

LeetCode 697. Degree of an Array

LeetCode 696. Count Binary Substrings

LeetCode 698. Partition to K Equal Sum Subsets

LeetCode 699. Falling Squares

[LeetCode]Falling Squares

题目描述:

LeetCode 699. Falling Squares

On an infinite number line (x-axis), we drop given squares in the order they are given.

The i-th square dropped (positions[i] = (left, side_length)) is a square with the left-most point being positions[i ...

继续阅读

[LeetCode]Partition to K Equal Sum Subsets

题目描述:

LeetCode 698. Partition to K Equal Sum Subsets

Given an array of integers nums and a positive integer k, find whether it's possible to divide this array into k non-empty subsets whose sums are all equal.

Example 1:

Input ...

继续阅读

年度归档