![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
cpp
文章平均质量分 74
dawn_ricardo_y
这个作者很懒,什么都没留下…
展开
-
[LeetCode] 最长公共子序列
题目这个问题就是最长公共子序列问题,区别与我之前做过的最长公共子串问题。典型的这类问题的形式如下: 有两个串:x和y,长度分别为m和n,求它们的最长公共子序列。分析这题主要就是两个方面。首先,对于其最长公共子序列z,肯定有以下两种情况的其中一种:z_k = x_m = y_n,此时,z_k-1肯定在剩下的子串x.substring(0, m-1) 和 y.substring原创 2018-01-13 14:56:02 · 1872 阅读 · 1 评论 -
[Leetcode][648][Replace Words] stringstream学习
题目描述In English, we have a concept called root, which can be followed by some other words to form another longer word - let’s call this word successor. For example, the root an, followed by other, wh...原创 2018-09-03 23:25:34 · 132 阅读 · 0 评论 -
[LeetCode] 417. Pacific Atlantic Water Flow
417. Pacific Atlantic Water Flow题目描述Given an m x n matrix of non-negative integers representing the height of each unit cell in a continent, the “Pacific ocean” touches the left and top edges of...原创 2018-09-09 20:57:49 · 142 阅读 · 0 评论 -
[LeetCode] 102. Binary Tree Level Order Traversal
题目描述Given a binary tree, return the level order traversal of its nodes’ values. (ie, from left to right, level by level).For example: Given binary tree [3,9,20,null,null,15,7], 3 / \ ...原创 2018-09-09 21:02:47 · 178 阅读 · 0 评论 -
[LeetCode] 467. Unique Substrings in Wraparound String
题目描述Consider the string s to be the infinite wraparound string of “abcdefghijklmnopqrstuvwxyz”, so s will look like this: “…zabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcd….”.Now we have...原创 2018-09-10 13:16:13 · 131 阅读 · 0 评论 -
[LeetCode] 795. Number of Subarrays with Bounded Maximum
题目描述We are given an array A of positive integers, and two positive integers L and R (L <= R).Return the number of (contiguous, non-empty) subarrays such that the value of the maximum array elem...原创 2018-09-10 19:22:45 · 112 阅读 · 0 评论