题目链接https://leetcode.com/problems/longest-common-prefix/题目原文
Write a function to find the longest common prefix string amongst an array of strings.
题目翻译写个函数,找出一个字符串数组中所有字符串的最长公共前缀。
题目描述不清晰。。。补充几个例子,...
分类:
编程语言 时间:
2016-06-21 07:26:30
阅读次数:
159
题目链接https://leetcode.com/problems/remove-linked-list-elements/题目原文
Remove all elements from a linked list of integers that have value val.
Example
Given: 1 –> 2 –> 6 –> 3 –> 4 –> 5 –> 6, val...
分类:
编程语言 时间:
2016-06-21 07:26:22
阅读次数:
166
题目链接https://leetcode.com/problems/binary-tree-paths/题目原文
Given a binary tree, return all root-to-leaf paths.
For example, given the following binary tree:
1
/ 2 3
5
All root-t...
分类:
编程语言 时间:
2016-06-21 07:25:49
阅读次数:
159
题目链接https://leetcode.com/problems/implement-strstr/题目原文
Implement strStr().
Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.
题目翻译实现 strSt...
分类:
编程语言 时间:
2016-06-19 09:01:07
阅读次数:
192
题目链接:http://www.lintcode.com/zh-cn/problem/the-smallest-difference/ 给定两个整数数组(第一个是数组 A,第二个是数组 B),在数组 A 中取 A[i],数组 B 中取 B[j],A[i] 和 B[j]两者的差越小越好(|A[i] - ...
分类:
编程语言 时间:
2016-06-18 23:59:43
阅读次数:
762
题目链接https://leetcode.com/problems/rectangle-area/题目原文
Find the total area covered by two rectilinear rectangles in a 2D plane.
Each rectangle is defined by its bottom left corner and top right c...
分类:
编程语言 时间:
2016-06-16 15:06:27
阅读次数:
327
题目链接https://leetcode.com/problems/merge-sorted-array/题目原文
Given two sorted integer arrays nums1 and nums2, merge nums2 into nums1 as one sorted array.
Note:
You may assume that nums1 has enou...
分类:
编程语言 时间:
2016-06-16 15:03:28
阅读次数:
227
题目链接https://leetcode.com/problems/isomorphic-strings/题目原文
Given two strings s and t, determine if they are isomorphic.
Two strings are isomorphic if the characters in s can be replaced to get t....
分类:
编程语言 时间:
2016-06-16 15:01:40
阅读次数:
272
题目: Write a function to delete a node (except the tail) in a singly linked list, given only access to that node. Supposed the linked list is 1 -> 2 -> ...
分类:
编程语言 时间:
2016-04-16 15:23:28
阅读次数:
299
题目: Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements. For example, ...
分类:
编程语言 时间:
2016-04-16 15:20:39
阅读次数:
149