- 博客(11)
- 收藏
- 关注
原创 LeetCode319. Bulb Switcher
here arenbulbs that are initially off. You first turn on all the bulbs. Then, you turn off every second bulb. On the third round, you toggle every third bulb (turning on if it's off or turning off i...
2019-07-25 08:10:09 117
原创 LeetCode318. Maximum Product of Word Lengths
Given a string arraywords, find the maximum value oflength(word[i]) * length(word[j])where the two words do not share common letters. You may assume that each word will contain only lower case lett...
2019-07-24 08:39:09 66
原创 LeetCode316. Remove Duplicate Letters
Given a string which contains only lowercase letters, remove duplicate letters so that every letter appear once and only once. You must make sure your result is the smallest in lexicographical order a...
2019-07-23 08:59:26 90
原创 LeetCode315. Count of Smaller Numbers After Self
You are given an integer arraynumsand you have to return a newcountsarray. Thecountsarray has the property wherecounts[i]is the number of smaller elements to the right ofnums[i].Example:...
2019-07-10 20:03:42 87
原创 LeetCode313. Super Ugly Number
Write a program to find thenthsuper ugly number.Super ugly numbers are positive numbers whose all prime factors are in the given prime listprimesof sizek.Example:Input: n = 12, primes = [2...
2019-07-09 09:19:56 163
原创 LeetCode312. Burst Balloons
Givennballoons, indexed from0ton-1. Each balloon is painted with a number on it represented by arraynums. You are asked to burst all the balloons. If the you burst ballooniyou will getnums[le...
2019-07-08 09:14:18 75
原创 LeetCode310. Minimum Height Trees
For an undirected graph with tree characteristics, we can choose any node as the root. The result graph is then a rooted tree. Among all possible rooted trees, those with minimum height are called min...
2019-07-06 17:40:42 127
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人