Given a string s and a string t, check if s is subsequence of t. You may assume that there is only lower case English letters in both s and t. t is po ...
分类:
其他好文 时间:
2020-05-11 13:14:30
阅读次数:
81
题目 You are given a positive integer N(1≦N≦1e18). Find the number of the pairs of integers u and v(0≦u,v≦N) such that there exist two non-negative inte ...
分类:
其他好文 时间:
2020-05-11 13:07:17
阅读次数:
68
"Problem Statement" You are given a positive integer $N$. Find the number of the pairs of integers $u$ and $v(0≤u,v≤N)$such that there exist two non n ...
分类:
其他好文 时间:
2020-05-10 19:32:45
阅读次数:
67
Given an undirected tree consisting of n vertices numbered from 0 to n-1, which has some apples in their vertices. You spend 1 second to walk over one ...
分类:
移动开发 时间:
2020-05-10 19:30:30
阅读次数:
71
Description Given a singly linked list, determine if it is a palindrome. Example 1: Example 2: Follow up: Could you do it in O(n) time and O(1) space? ...
分类:
其他好文 时间:
2020-05-10 15:24:52
阅读次数:
77
package LeetCode_504 /** * 504. Base 7 (7进制) * https://leetcode.com/problems/base-7/description/ * Given an integer, return its base 7 string represen ...
分类:
其他好文 时间:
2020-05-10 14:50:02
阅读次数:
44
"题目" You are given a weighed undirected connected graph, consisting of $n$ vertices and $m$ edges. You should answer $q$ queries, the $i$ th query is ...
分类:
其他好文 时间:
2020-05-09 19:04:20
阅读次数:
66
题目 You are given a weighed undirected connected graph, consisting of n vertices and m edges. You should answer q queries, the i th query is to find th ...
分类:
其他好文 时间:
2020-05-08 22:56:50
阅读次数:
83
The task is simple: given any positive integer N, you are supposed to count the total number of 1's in the decimal form of the integers from 1 to N. F ...
分类:
其他好文 时间:
2020-05-08 22:56:07
阅读次数:
76
Given a stack which can keep M numbers at most. Push N numbers in the order of 1, 2, 3, ..., N and pop randomly. You are supposed to tell if a given s ...
分类:
其他好文 时间:
2020-05-08 18:36:48
阅读次数:
75