- 博客(4)
- 收藏
- 关注
原创 LeetCode--Sum Root to Leaf Numbers
临近期末考试,最近可能要刷一些前面学到的知识对应的类型题,以及会多放一些题解到博客上。Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number.An example is the root-to-leaf path 1->2->3 which
2017-12-24 16:20:16 126
原创 LeetCode--Best Time to Buy and Sell Stock with Cooldown
Say you have an array for which the ith element is the price of a given stock on dayi.Design an algorithm to find the maximum profit. You may complete as many transactions as you like (ie, buy one
2017-12-18 00:25:09 124
原创 LeetCode--Ugly Number II
Write a program to find the n-th ugly number.Ugly numbers are positive numbers whose prime factors only include 2, 3, 5. For example,1, 2, 3, 4, 5, 6, 8, 9, 10, 12 is the sequence of the first 10
2017-12-10 14:41:01 197
原创 LeetCode--Palindromic Substrings
Given a string, your task is to count how many palindromic substrings in this string.The substrings with different start indexes or end indexes are counted as different substrings even they consist
2017-12-03 22:40:05 106
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人