佛奴儿
佛奴儿
全部文章
未归档
归档
标签
去牛客网
登录
/
注册
Roni
ACMer
全部文章
/ 未归档
(共985篇)
160. Intersection of Two Linked Lists【Easy】【求两个单链表的第一个交点】
Write a program to find the node at which the intersection of two singly linked lists begins. For example, the following two linked lists: b...
2019-02-27
0
491
203. Remove Linked List Elements【Easy】【未排序链表删除其中的给定值】
Remove all elements from a linked list of integers that have value val. Example: Input: 1->2->6->3->4->5->6, val = 6 Output: 1-&g...
2019-02-27
0
431
234. Palindrome Linked List【Easy】【判断链表是否回文】
Given a singly linked list, determine if it is a palindrome. Example 1: Input: 1->2 Output: false Example 2: Input: 1->2->2->1 Output:...
2019-02-27
0
386
543. Diameter of Binary Tree【Easy】【二叉树的直径】
Given a binary tree, you need to compute the length of the diameter of the tree. The diameter of a binary tree is the length of the longest path betwe...
2019-02-26
0
416
114. Flatten Binary Tree to Linked List【Medium】【将给定的二叉树转化为“只有右孩子节点”的链表(树)】
Given a binary tree, flatten it to a linked list in-place. For example, given the following tree: 1 / \ 2 5 / \ \ 3 4 6 Th...
2019-02-25
0
722
Java实现蛇形矩阵
public class Solution { //下x++ 左y-- 上x-- 右y++ public void prints(int n) { int[][] mp = new int[n][n]; for(int i=0; i&...
2019-02-25
0
391
215. Kth Largest Element in an Array【Medium】【找到第 k 大的元素】
Find the kth largest element in an unsorted array. Note that it is the kth largest element in the sorted order, not the kth distinct elem...
2019-02-25
0
473
524. Longest Word in Dictionary through Deleting【Medium】【删除后得到的字典中的最长单词】
Given a string and a string dictionary, find the longest string in the dictionary that can be formed by deleting some characters of the given string. ...
2019-02-25
0
376
141. Linked List Cycle【Easy】【判断链表是否存在环】
Given a linked list, determine if it has a cycle in it. To represent a cycle in the given linked list, we use an integer pos which represents the p...
2019-02-25
0
440
88. Merge Sorted Array【Easy】【双指针-不用额外空间归并两个有序数组】
Given two sorted integer arrays nums1 and nums2, merge nums2 into nums1 as one sorted array. Note: The number of elements initialized in nu...
2019-02-24
0
403
首页
上一页
6
7
8
9
10
11
12
13
14
15
下一页
末页