场景切换是通过导演类Director实现的,其中的相关函数如下:runWithScene(Scene* scene)。该函数可以运行场景。只能在启动第一个场景时候调用该函数。如果已经有一个场景运行情况下则不能调用该函数。replaceScene(Scene* scene)。切换到下一个场景。用一个新的场景替换当前场景,当前场景被终端释放。pushScene(Scene* scene)。切换到下一个...
分类:
其他好文 时间:
2014-06-03 01:39:32
阅读次数:
275
按图论列表上来说是基础题。
这道题是省赛之前过的,现在想再拿出来总结一下,感觉这个类型的题很经典。
题意不叙述了,就是有奶牛和机器,每台奶牛分配一个机器,
牛与牛、牛与机器、机器与机器之间都有一距离,求分配后的最大距离的最小值。
一开始没明白啥叫“最大距离的最小值”,就是C头奶牛、K个挤奶器,C头奶牛若想到全部的挤奶器那里去需要一定的距离,
C头奶牛当中某一头奶牛需要走的...
分类:
其他好文 时间:
2014-06-03 03:23:52
阅读次数:
234
链接:http://acm.hrbust.edu.cn/index.php?m=ProblemSet&a=showProblem&problem_id=2040
Description:
给出一棵二叉树的中序和前序遍历,输出它的后序遍历。
Input
本题有多组数据,输入处理到文件结束。
每组数据的第一行包括一个整数n,表示这棵二叉树一共有n个节点。
接下来的一行每行包括n个整数,表示...
分类:
其他好文 时间:
2014-06-03 03:10:46
阅读次数:
236
An iterative way of writing merge sort:
#include
using namespace std;
void merge(int A[], int l, int r, int e, int B[]) {
int i = l, j = r, k = l;
while (i<r && j A[j]) B[k++] =...
分类:
其他好文 时间:
2014-06-03 02:33:24
阅读次数:
215
这一篇是接着上一篇的继续
页面跳转与重定向(之一)
在上一篇中, 介绍了在html,js 和JSP中如何跳转和重定向。
基本是在页面层级进行页面的跳转, 进入一个页面后跳入另一个页面。
这一篇将从项目和服务端来看看有可能在实际的项目中使用到的状况。...
分类:
其他好文 时间:
2014-06-03 03:04:11
阅读次数:
275
链接: http://acm.hrbust.edu.cn/index.php?m=ProblemSet&a=showProblem&problem_id=2116
Description
Wind and his GF(game friend) are playing a small game. They use the computer to randomly generated a nu...
分类:
其他好文 时间:
2014-06-03 02:17:13
阅读次数:
252
String,StringBuffer和StringBuilder的异同
String,StringBuffer和StringBuilder的的源码已经在本博客的JDK源码学习系列中有了详细的介绍:
String 源码: http://blog.csdn.net/sheepmu/article/details/23303837
StringBuffer 和StringBuil...
分类:
其他好文 时间:
2014-06-03 05:45:58
阅读次数:
211
There is no systematic design for shared resource access priority in platform side, and there is no interface provided by
platform that can be used by application to do bandwidth management optimizat...
分类:
其他好文 时间:
2014-06-03 04:54:35
阅读次数:
262
原创博客,转载请:http://blog.csdn.net/zhjm07054115/article/details/27577181...
分类:
其他好文 时间:
2014-06-03 04:53:59
阅读次数:
276
Given a singly linked list
L: L0→L1→…→Ln-1→Ln,
reorder it to: L0→Ln→L1→Ln-1→L2→Ln-2→…
You must do this in-place without altering the nodes' values.
For example,
Given {1,2,3,4}, r...
分类:
其他好文 时间:
2014-06-03 03:12:46
阅读次数:
222