Given an array of non-negative integers, you 
are initially positioned at the first index of the array.Each element in the 
array represents your maximu...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 20:58:25   
                                阅读次数:
296
                             
                    
                        
                            
                            
                                Given an array of non-negative integers, you 
are initially positioned at the first index of the array.Each element in the 
array represents your maximu...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 20:44:19   
                                阅读次数:
216
                             
                    
                        
                            
                            
                                You are given annxn2D matrix representing an 
image.Rotate the image by 90 degrees (clockwise).Follow up:Could you do this 
in-place?classSolution{publi...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 20:25:09   
                                阅读次数:
227
                             
                    
                        
                            
                            
                                Given two wordsword1andword2, find the minimum 
number of steps required to convertword1toword2. (each operation is counted as 1 
step.)You have the fol...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 20:12:15   
                                阅读次数:
199
                             
                    
                        
                            
                            
                                Given a set ofnon-overlappingintervals, insert 
a new interval into the intervals (merge if necessary).You may assume that the 
intervals were initially...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 20:10:23   
                                阅读次数:
204
                             
                    
                        
                            
                            
                                Given an array of words and a lengthL, format 
the text such that each line has exactlyLcharacters and is fully (left and 
right) justified.You should p...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 20:08:22   
                                阅读次数:
296
                             
                    
                        
                            
                            
                                You are climbing a stair case. It takesnsteps 
to reach to the top.Each time you can either climb 1 or 2 steps. In how many 
distinct ways can you climb...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 19:53:34   
                                阅读次数:
173
                             
                    
                        
                            
                            
                                Given an integern, generate a square matrix 
filled with elements from 1 ton2in spiral order.For example,Givenn=3,You should 
return the following matri...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 19:28:23   
                                阅读次数:
220
                             
                    
                        
                            
                            
                                Given two sorted integer arrays A and B, merge 
B into A as one sorted array.Note:You may assume that A has enough space (size 
that is greater or equal...
                            
                            
                                分类:
其他好文   时间:
2014-06-04 18:18:08   
                                阅读次数:
259
                             
                    
                        
                            
                            
                                Given a linked list and a valuex, partition it 
such that all nodes less thanxcome before nodes greater than or equal tox.You 
should preserve the origi...
                            
                            
                                分类:
其他好文   时间:
2014-06-03 14:12:24   
                                阅读次数:
306