自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(27)
  • 收藏
  • 关注

转载 Job Hunting Suggestions

Online job sites:Visit two kinds of job sites as part of your research:Dice(which specializes in technology-related career listings)Monster (a general job listing site)Glassdoor andCareerBli

2017-01-06 13:28:06 289

转载 国内面试

作者:张云聪链接:https://www.zhihu.com/question/24517661/answer/28282613来源:知乎著作权归作者所有,转载请联系作者获得授权。答:一般大公司都需要准备以下方面:1.学好计算机专业考研的四门专业课程(计算机组成原理、数据结构、操作系统、网络原理)2.精通一门编程语言。3.提高算法功底与数学思维能力。 一般会问你几个常见

2017-01-06 13:26:24 248

转载 HashMap的工作原理

HashMap的工作原理是近年来常见的Java面试题。几乎每个Java程序员都知道HashMap,都知道哪里要用HashMap,知道Hashtable和HashMap之间的区别,那么为何这道面试题如此特殊呢?是因为这道题考察的深度很深。这题经常出现在高级或中高级面试中。投资银行更喜欢问这个问题,甚至会要求你实现HashMap来考察你的编程能力。ConcurrentHashMap和其它同步集合的引入

2017-01-04 22:28:37 188

转载 硅谷跳槽工具箱指南

原地址:https://zhuanlan.zhihu.com/p/19953744?columnSlug=donglaoshi作者:董飞链接:https://zhuanlan.zhihu.com/p/19953744来源:知乎著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。前言这是我在硅谷找工作用到的一些资料和网站,虽然都是英文的,但都是

2017-01-02 21:18:11 175

原创 Rotate List

Given a list, rotate the list to the right by k places, where k is non-negative.ExampleGiven 1->2->3->4->5 and k = 2, return 4->5->1->2->3./** * Definition for singly-linked lis

2016-12-21 14:23:14 190

原创 Swap Two Nodes in Linked List

Given a linked list and two values v1 and v2. Swap the two nodes in the linked list with values v1 and v2. It's guaranteed there is no duplicate values in the linked list. If v1 or v2 does not exist i

2016-12-21 13:42:22 203

原创 Delete Node in the Middle of Singly Linked List

Implement an algorithm to delete a node in the middle of a singly linked list, given only access to that node.ExampleGiven 1->2->3->4, and node 3. return 1->2->4/** * Definition for

2016-12-21 10:52:52 185

原创 Construct Binary Tree from Inorder and Postorder Traversal

Given inorder and postorder traversal of a tree, construct the binary tree. NoticeYou may assume that duplicates do not exist in the tree.Given inorder [1,2,3] and postorder [1,3

2016-12-21 10:35:46 196

原创 Construct Binary Tree from Preorder and Inorder Traversal

Given preorder and inorder traversal of a tree, construct the binary tree. NoticeYou may assume that duplicates do not exist in the tree.ExampleGiven in-order [1,2,3] and pre-order

2016-12-20 15:58:10 207

原创 Complete Binary Tree

Check a binary tree is completed or not. A complete binary tree is a binary tree that every level is completed filled except the deepest level. In the deepest level, all nodes must be as left as possi

2016-12-20 10:32:49 237

原创 Subsets vs Permutations

SubsetsGiven a set of distinct integers, return all possible subsets. NoticeElements in a subset must be in non-descending order.The solution set must not contain duplicate subsets.

2016-12-16 16:48:06 180

原创 Sort Colors

Given an array with n objects colored red, white or blue, sort them so that objects of the same color are adjacent, with the colors in the order red, white and blue.Here, we will use the integers 

2016-12-16 11:47:59 135

原创 Subarray Sum Closest

Given an integer array, find a subarray with sum closest to zero. Return the indexes of the first number and last number.ExampleGiven [-3, 1, 1, -3, 5], return [0, 2], [1, 3], [1, 1], [2

2016-12-14 16:14:24 154

转载 Maximum Subarray

Given an array of integers, find a contiguous subarray which has the largest sum. NoticeThe subarray should contain at least one number.ExampleGiven the array [−2,2,−3,4,−1,2,1,−5,

2016-12-14 15:45:58 115

原创 Subarray Sum

Given an integer array, find a subarray where the sum of numbers is zero. Your code should return the index of the first number and the index of the last number. NoticeThere is at least one

2016-12-14 15:26:46 177

原创 Sort List

Sort a linked list in O(n log n) time using constant space complexity.Merge sort/** * Definition for ListNode. * public class ListNode { * int val; * ListNode next; * ListNo

2016-12-14 14:11:50 124

原创 Merge k Sorted Lists

Merge k sorted linked lists and return it as one sorted list.Analyze and describe its complexity.ExampleGiven lists:[ 2->4->null, null, -1->null],return -1->2->4-

2016-12-14 12:10:45 208

原创 Copy List with Random Pointer

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 of the list./** * Definition for singly-lin

2016-12-14 11:53:24 133

原创 Partition List

Given a linked list and a value x, partition it such that all nodes less than x come before nodes greater than or equal to x.You should preserve the original relative order of the nodes in each of

2016-12-14 11:17:04 128

原创 Binary Tree Maximum Path Sum

Given a binary tree, find the maximum path sum.The path may start and end at any node in the tree./** * Definition of TreeNode: * public class TreeNode { * public int val; * pu

2016-12-13 14:49:05 250

原创 Inorder Successor in Binary Search Tree

Given a binary search tree (See Definition) and a node in it, find the in-order successor of that node in the BST.If the given node has no in-order successor in the tree, return null.

2016-12-13 14:45:31 177

原创 Search in Rotated Sorted Array

Suppose a sorted array is rotated at some pivot unknown to you beforehand.(i.e., 0 1 2 4 5 6 7 might become 4 5 6 7 0 1 2).You are given a target value to search. If found in the array retur

2016-12-13 11:18:44 112

原创 Find Peak Element

There is an integer array which has the following features:The numbers in adjacent positions are different.A[0] A[A.length - 1].We define a position P is a peek if:A[P] > A[P-1] && A[P]

2016-12-13 10:52:28 402

原创 Find Minimum in Rotated Sorted Array

Suppose a sorted array is rotated at some pivot unknown to you beforehand.(i.e., 0 1 2 4 5 6 7 might become 4 5 6 7 0 1 2).Find the minimum element. NoticeYou may assume no

2016-12-13 10:50:35 144

原创 Wood Cut

Given n pieces of wood with length L[i] (integer array). Cut them into small pieces to guarantee you could have equal or more than k pieces with the same length. What is the longest length you can g

2016-12-13 10:44:48 196

原创 Search in a Big Sorted Array

Given a big sorted array with positive integers sorted by ascending order. The array is so big so that you can not get the length of the whole array directly, and you can only access the kth number by

2016-12-13 10:42:05 921

原创 last position of target / first position of target

Last Position of TargetFind the last position of a target number in a sorted array. Return -1 if target does not exist.O(log n)public class Solution { /** * @param nums: An integer arra

2016-12-13 10:27:52 319

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除