摘要:
(转)http://www.cnblogs.com/shudonghe/p/3457990.html文主要介绍,JVM的组件,自动垃圾收集器是如何工作的,分代垃圾收集器的收集过程,使如何用Visual VM来监视应用的虚拟机,以及JVM中垃圾收集器的种类。一、JVM架构1、HotSpot 架构Hot... 阅读全文
摘要:
A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null.Return a deep copy ... 阅读全文
摘要:
Given a linked list, return the node where the cycle begins. If there is no cycle, returnnull.Follow up:Can you solve it without using extra space?思想:... 阅读全文
摘要:
Sort a linked list inO(nlogn) time using constant space complexity.思想: divede and conquer,利用主定理公式,复杂度为O(nlogn).先用slow和fast指针分解两个链表,第一个链表的尾部节点为null。然后用... 阅读全文
摘要:
Given n points on a 2D plane, find the maximum number of points that lie on the same straight line.思想:以一个点为起点,计算以该点为起点的所有不同斜率上点的数目,从中挑选最大值。java 代码: 注意... 阅读全文
摘要:
Reverse digits of an integer.Example1:x = 123, return 321Example2:x = -123, return -321click to show spoilers.Have you thought about this?Here are som... 阅读全文
摘要:
With its new OS release, Apple has discontinued the use ofGDBin OS X. Since 2005 Apple has steadily been moving away from the GNU toolchain in favor o... 阅读全文
摘要:
Determine whether an integer is a palindrome. Do this without extra space.click to show spoilers.Some hints:Could negative integers be palindromes? (i... 阅读全文
摘要:
Given an unsorted array of integers, find the length of the longest consecutive elements sequence.For example,Given[100, 4, 200, 1, 3, 2],The longest ... 阅读全文