- 博客(15)
- 收藏
- 关注
原创 匿名内部类引起的内存泄露——Handler和Thread
匿名内部类会持有外部类的引用,当内部类进行延时操作的时候,如果外部类是Activity,那么在执行destroy后,并不会被销毁,从而导致内存泄漏
2016-05-06 13:23:55
4359
原创 Python学习——leetcode(Valid Parentheses)
Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid.The brackets must close in the correct order, "()" and "()[]{}" are all valid but "(]" and "([)]" are not.括号匹配问题
2014-12-18 15:37:08
376
原创 Python学习——leetcode(Balanced Binary Tree)
Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as a binary tree in which the depth of the two subtrees of every node never differ by more than 1.如何判断一个二叉树是否为平衡二叉树,用python代码实现
2014-12-18 14:21:52
424
原创 Python学习——leetcode(Intersection of Two Linked Lists)
Write a program to find the node at which the intersection of two singly linked lists begins.
2014-12-18 13:59:51
377
原创 Python学习——leetcode(Binary Tree Level Order Traversal)
Given a binary tree, return the level order traversal of its nodes' values. (ie, from left to right, level by level).
2014-12-18 13:22:17
351
原创 Python学习——leetcode(Compare Version Numbers)
Compare two version numbers version1 and version1.If version1 > version2 return 1, if version1 < version2 return -1, otherwise return 0.You may assume that the version strings are non-empty and contain only digits and the . character.The . character doe
2014-12-17 19:27:00
640
原创 Python学习——leetcode(Length of Last Word)
Given a string s consists of upper/lower-case alphabets and empty space characters ' ', return the length of last word in the string.If the last word does not exist, return 0.Note: A word is defined as a character sequence consists of non-space character
2014-12-17 16:36:46
691
原创 Python学习——leetcode(Merge Two Sorted Lists )
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.
2014-12-16 18:04:43
337
原创 Python学习——leetcode(Add Binary)
Add Binary:Given two binary strings, return their sum (also a binary string).For example,a = "11"b = "1"Return "100".
2014-12-16 16:32:29
475
原创 Python学习——leetcode(Remove Duplicates from Sorted List)
Remove Duplicates from Sorted List-------Python accepted
2014-12-15 19:10:18
390
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人