queue
----------------------------------------------------------------------
stack 是一种配接器(adapter),以某种容器作为底部结构,改变其接口,使之符合"先进先出"的特性。
SGI STL 默认以 deque 为 stack 底部结构
没有遍历行为,没有遍历器
示例:
#include
#include
#include
#include
...
分类:
其他好文 时间:
2014-07-22 00:30:38
阅读次数:
230
stack
-------------------------------------------------------------
stack 是一种配接器(adapter),以某种容器作为底部结构,改变其接口,使之符合"先进后出"的特性。
SGI STL 默认以 deque 为 stack 底部结构
没有遍历行为,没有遍历器
示例:
#include
#include
#include
#include
using names...
分类:
其他好文 时间:
2014-07-22 00:28:39
阅读次数:
212
DFS and using stack to validate candidates.class Solution {public: bool isValid(const string &s) { stack stk; for (int i = 0; i &...
分类:
其他好文 时间:
2014-07-22 00:28:34
阅读次数:
217
我们浏览网页的时候,当单击某段文字或图片时,就会打开一个新的网页,这里面就使用了超链接。 就比如下图是一个导航类网页,当你单击某个链接就会打开新的网页。 比如,我拿我的qq空间“金河访谈”举例,新建一个网页 a.html,输入下面的内容:html中的超链接标签-a标签1,直接转向其他页面:金...
分类:
Web程序 时间:
2014-07-21 10:01:36
阅读次数:
475
Frame StackingTime Limit:1000MSMemory Limit:10000KTotal Submissions:4034Accepted:1352DescriptionConsider the following 5 picture frames placed on an 9...
分类:
其他好文 时间:
2014-07-21 00:04:17
阅读次数:
399
如下图:
这里我们实现DFS中的三种遍历方法。
相关的如下:
相关算法的介绍不再赘述。
首先对于preorder traversal 的步骤为:
其他两种算法略。
具体递归调用分析, 注意学会画stack frame的图分析。 这里不再赘述。
代码如下:
/* Binary Tree Traversal - Preorder, Inorder, Postor...
分类:
编程语言 时间:
2014-07-20 23:05:10
阅读次数:
365
关于动画的实现,Android提供了Animation,在Android SDK介绍了2种Animation模式:1. Tween Animation:通过对场景里的对象不断做图像变换(平移、缩放、旋转)产生动画效果,即是一种渐变动画;2. Frame Animation:顺序播放事先做好的图像,是...
分类:
移动开发 时间:
2014-07-20 22:27:40
阅读次数:
347
一、什么是Grails?
Grails is an Open Source, full stack, web application framework for the JVM. It takes advantage of the Groovy programming language and convention over configuration to provide a producti...
分类:
其他好文 时间:
2014-07-19 23:18:40
阅读次数:
240
contentSize:The size of the content view. 其实就是scrollview可以滚动的区域,比如frame = (0 ,0 ,320 ,480) contentSize = (320 ,960),代表你的scrollview可以上下滚动,滚动区域为frame大小的...
分类:
其他好文 时间:
2014-07-19 09:03:08
阅读次数:
203