上一页 1 ··· 6 7 8 9 10 11 下一页

2016年4月22日

摘要: Given a linked list, swap every two adjacent nodes and return its head. For example,Given 1->2->3->4, you should return the list as 2->1->4->3. Your a 阅读全文
posted @ 2016-04-22 10:42 烁宝宝 阅读(152) 评论(0) 推荐(0)

2016年4月21日

摘要: The count-and-say sequence is the sequence of integers beginning as follows: 1, 11, 21, 1211, 111221, ... 1 is read off as "one 1" or 11.11 is read of 阅读全文
posted @ 2016-04-21 20:56 烁宝宝 阅读(161) 评论(0) 推荐(0)

2016年4月20日

摘要: 1 public class Solution { 2 public String addBinary(String a, String b) { 3 char[] aa=a.toCharArray(); 4 char[] bb=b.toCharArray(); 5 6 int size=aa.leng... 阅读全文
posted @ 2016-04-20 21:38 烁宝宝 阅读(169) 评论(0) 推荐(0)
 
摘要: Given a sorted linked list, delete all duplicates such that each element appear only once. For example,Given 1->1->2, return 1->2.Given 1->1->2->3->3, 阅读全文
posted @ 2016-04-20 20:53 烁宝宝 阅读(152) 评论(0) 推荐(0)
 
摘要: Given two binary trees, write a function to check if they are equal or not. Two binary trees are considered equal if they are structurally identical a 阅读全文
posted @ 2016-04-20 20:43 烁宝宝 阅读(179) 评论(0) 推荐(0)
 
摘要: Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest l 阅读全文
posted @ 2016-04-20 20:22 烁宝宝 阅读(152) 评论(0) 推荐(0)
 
摘要: Given a binary tree, find its minimum depth. The minimum depth is the number of nodes along the shortest path from the root node down to the nearest l 阅读全文
posted @ 2016-04-20 18:53 烁宝宝 阅读(141) 评论(0) 推荐(0)
 
摘要: Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum. F 阅读全文
posted @ 2016-04-20 15:54 烁宝宝 阅读(154) 评论(0) 推荐(0)
 
摘要: Write a program to find the node at which the intersection of two singly linked lists begins. For example, the following two linked lists: begin to in 阅读全文
posted @ 2016-04-20 12:43 烁宝宝 阅读(157) 评论(0) 推荐(0)
 
摘要: Remove all elements from a linked list of integers that have value val. ExampleGiven: 1 --> 2 --> 6 --> 3 --> 4 --> 5 --> 6, val = 6Return: 1 --> 2 -- 阅读全文
posted @ 2016-04-20 09:48 烁宝宝 阅读(114) 评论(0) 推荐(0)
上一页 1 ··· 6 7 8 9 10 11 下一页