- 博客(6)
- 资源 (10)
- 收藏
- 关注
原创 Path Sum —— Leetcode
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.For example:Given the below binary tree and sum
2015-04-29 20:28:08 485
原创 Merge Two Sorted Lists —— Leetcode(再做一遍)
Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists.很简单的一道题,为什么做的时候就意识模糊了呢?另外,注意头结点解决边界条件的方法,不需要事先将链表头给he
2015-04-29 20:02:34 381
原创 Happy Number —— Leetcode
Write an algorithm to determine if a number is "happy".A happy number is a number defined by the following process: Starting with any positive integer, replace the number by the sum of the squares
2015-04-29 15:33:34 679
原创 Isomorphic Strings —— Leetcode
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.All occurrences of a character must be replaced with anot
2015-04-29 11:00:28 775
原创 Remove Linked List Elements —— Leetcode
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 --> 3 --> 4 --> 5链表操作的题目,一般在链表中,对头结点的边界操作
2015-04-29 10:24:58 774
原创 Palindrome Number —— Leetcode(再做一遍)
Determine whether an integer is a palindrome. Do this without extra space.Some hints:Could negative integers be palindromes? (ie, -1)If you are thinking of converting the integer to string
2015-04-09 22:23:09 650
Cisco IP Routing: Packet Forwarding and Intra-domain Routing Protocols
2012-05-03
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人