二、栈与队列 1、栈的定义 栈(Stack)是限制仅在表的一端进行插入和删除运算的线性表。 
(1)通常称插入、删除的这一端为栈顶(Top),另一端称为栈底(Bottom)。 (2)当表中没有元素时称为空栈。 (3)栈为后进先出(Last In 
First Out)的线性表,简称为LI...
                            
                            
                                分类:
编程语言   时间:
2014-05-06 09:00:26   
                                阅读次数:
414
                             
                    
                        
                            
                            
                                Say you have an array for which theithelement 
is the price of a given stock on dayi.Design an algorithm to find the maximum 
profit. You may complete a...
                            
                            
                                分类:
其他好文   时间:
2014-05-06 00:51:29   
                                阅读次数:
353
                             
                    
                        
                            
                            
                                这3个系列的书我买了不少本,虽然没有都读完,但是还是要做个阶段性的评价for 
dummies:即阿呆系列,外教老师Chris说那是入门的书,知识量少,我觉得自己开辟一个新的学习计划时,这个系列的书是很有帮助的,细分两个子系列all-in-one 
for dummies:这个系列的书厚些,通常是几本书...
                            
                            
                                分类:
其他好文   时间:
2014-05-05 23:16:11   
                                阅读次数:
272
                             
                    
                        
                            
                            
                                今天阅读《Outlook 2010 Inside Out》时,上机操作时有几个小发现win 7 
自带截屏工具(360浏览器有,SnagIt更强大)win 
7自带便签纸(当然比不上Outlook中的便签,更不能与OneNote比了!)程序中百宝箱内有ReadyFor4GB.exe可帮助突破32位4G内...
                            
                            
                                分类:
其他好文   时间:
2014-05-05 23:14:25   
                                阅读次数:
356
                             
                    
                        
                            
                            
                                Problem 
Link:http://oj.leetcode.com/problems/longest-consecutive-sequence/This problem 
is a classical problem where we can reduce the running time by ...
                            
                            
                                分类:
其他好文   时间:
2014-05-05 22:55:22   
                                阅读次数:
552
                             
                    
                        
                            
                            
                                Link:http://oj.leetcode.com/problems/reverse-nodes-in-k-group/Given a linked 
list, reverse the nodes of a linked listkat a time and return its modifie...
                            
                            
                                分类:
其他好文   时间:
2014-05-05 22:46:42   
                                阅读次数:
456
                             
                    
                        
                            
                            
                                拼图Time Limit:1000MSMemory 
Limit:65535KBSubmissions:117Accepted:69Description给你1x2、2x1和2x2,3种矩形若干,请你计算出把它们放入2xn的矩形中,一共有多少方法?Input输入有多组测试数据没行输入一个整数n 
, 3...
                            
                            
                                分类:
其他好文   时间:
2014-05-05 22:35:15   
                                阅读次数:
435
                             
                    
                        
                            
                            
                                挑战题之排列生成Time Limit:2000MSMemory 
Limit:65535KBSubmissions:435Accepted:170Description一自然数N,设N为3,则关于N的字典序排列为123,132,213,231,312,321。对于一个自然数N(1#include 
us...
                            
                            
                                分类:
其他好文   时间:
2014-05-05 22:25:33   
                                阅读次数:
294
                             
                    
                        
                            
                            
                                列表推导式(list 
comprehension)是利用其他列表创建新列表(类似于数学术语中的集合推导式)的一种方法。它的工作方式类似于for循环,也很简单:In [39]: 
[x*x for x in range(10)]Out[39]: [0, 1, 4, 9, 16, 25, 36, 49, ...
                            
                            
                                分类:
编程语言   时间:
2014-05-05 22:21:48   
                                阅读次数:
422
                             
                    
                        
                            
                            
                                A + B
Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 11543    Accepted Submission(s): 6699
Problem Description
 
读入两个小于100的正整数A和B,计...
                            
                            
                                分类:
其他好文   时间:
2014-05-03 16:00:57   
                                阅读次数:
270