mrlonelyjtr's blog

写BUG的程序猿


  • Home

  • Categories

  • Archives

  • Tags

  • Search

[LeetCode] Problem 279 - Perfect Squares

Posted on 2019-05-15 | In Algorithm , LeetCode
Given a positive integer n, find the least number of perfect square numbers (for example, 1, 4, 9, 16, …) which sum to n. ExampleNo.1Input: n = 12 Out ...
Read more »

[LeetCode] Problem 204 - Count Primes

Posted on 2019-05-15 | In Algorithm , LeetCode
Count the number of prime numbers less than a non-negative number, n. ExampleInput: 10 Output: 4 Explanation: There are 4 prime numbers less than 10, ...
Read more »

[LeetCode] Problem 558 - Quad Tree Intersection

Posted on 2019-05-15 | In Algorithm , LeetCode
A quadtree is a tree data in which each internal node has exactly four children: topLeft, topRight, bottomLeft and bottomRight. Quad trees are often u ...
Read more »

[LeetCode] Problem 427 - Construct Quad Tree

Posted on 2019-05-14 | In Algorithm , LeetCode
We want to use quad trees to store an N x N boolean grid. Each cell in the grid can only be true or false. The root node represents the whole grid. Fo ...
Read more »

[LeetCode] Problem 696 - Count Binary Substrings

Posted on 2019-05-13 | In Algorithm , LeetCode
Give a string s, count the number of non-empty (contiguous) substrings that have the same number of 0’s and 1’s, and all the 0’s and all the 1’s in th ...
Read more »

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

Posted on 2019-05-13 | In Algorithm , LeetCode
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 integer fee represen ...
Read more »

[LeetCode] Problem 309 - Best Time to Buy and Sell Stock with Cooldown

Posted on 2019-05-13 | In Algorithm , LeetCode
Say you have an array for which the ith element is the price of a given stock on day i. Design an algorithm to find the maximum profit. You may comple ...
Read more »

[LeetCode] Problem 122 - Best Time to Buy and Sell Stock II

Posted on 2019-05-13 | In Algorithm , LeetCode
Say you have an array for which the ith element is the price of a given stock on day i. Design an algorithm to find the maximum profit. You may comple ...
Read more »

[LeetCode] Problem 121 - Best Time to Buy and Sell Stock

Posted on 2019-05-13 | In Algorithm , LeetCode
Say you have an array for which the ith element is the price of a given stock on day i. If you were only permitted to complete at most one transaction ...
Read more »

[LeetCode] Problem 958 - Check Completeness of a Binary Tree

Posted on 2019-05-10 | In Algorithm , LeetCode
Given a binary tree, determine if it is a complete binary tree. Definition of a complete binary tree from Wikipedia:In a complete binary tree every le ...
Read more »
1…404142…78
mrlonelyjtr

mrlonelyjtr

间歇性踌躇满志,持续性混吃等死

780 posts
18 categories
18 tags
Github
© 2020 mrlonelyjtr
Powered by Hexo
Theme - NexT.Pisces