摘要:
开始研究cocos2dx,mark一下这个的配置步骤 1 下载eclipse 2 下载android sdk,配置sdk路径,添加环境变量 3 安装adt 4 下载android ndk,配置ndk路径 5 下载cocos2dx 开发包 注意 ndk8+ 不需要cygwin,可以省去N多下载的时间 下载cygwin的时候蛋快碎了感觉好慢,不过用过linux的可以试试用cygwin,有些人说用cygwin好点。 这里我下载的是ndk9 并且放在E:\ndkr9下,配置环境变量。这里的cygwin可以不下载不用配置。 前面的安装大哥们自己百度安装下吧~~ 然后我们打开ecl...
阅读全文
posted @ 2013-10-29 22:31
you Richer
阅读(443)
推荐(0)
摘要:
# -*- coding: cp936 -*-import poplibimport randomimport osdef getmail(): # 蒋辉文拥有该程序权利 你可以随意使用 emailServer = poplib.POP3('pop.163.com') emailServer.user('xxxxxxxxxxxxxx') emailServer.pass_('xxxxxxxxxxxxxx') # 设置为1,可查看向pop3服务器提交了什么命令 #emailServer.set_debuglevel(1) ...
阅读全文
posted @ 2013-10-29 22:31
you Richer
阅读(584)
推荐(0)
摘要:
#includeusing namespace std;int n,Max,C[4][4];char board[5][5];bool vis[16];bool isok(int x,int y){ for (int i = x + 1; i = 0 && board[i][y] != 'X'; i--) if(board[i][y] == '0') return false; for (int i = y; i = 0 && board[x][i] != 'X'; i--) if (board[x][i] ==
阅读全文
posted @ 2013-10-29 22:27
you Richer
阅读(195)
推荐(0)
摘要:
TOYSTime Limit: 2000MSMemory Limit: 65536KTotal Submissions: 9310Accepted: 4436Description Calculate the number of toys that land in each bin of a partitioned toy box. Mom and dad have a problem - their child John never puts his toys away when he is finished playing with them. They gave John a rect.
阅读全文
posted @ 2013-10-29 22:25
you Richer
阅读(171)
推荐(0)
摘要:
DescriptionA Strict Weak Ordering is aBinary Predicatethat compares two objects, returningtrueif the first precedes the second. This predicate must satisfy the standard mathematical definition of astrict weak ordering. The precise requirements are stated below, but what they roughly mean is that a S
阅读全文
posted @ 2013-10-29 22:24
you Richer
阅读(309)
推荐(0)
摘要:
TravelTime Limit: 10000/5000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 2621Accepted Submission(s): 720 Problem Description PP loves travel. Her dream is to travel around country A which consists of N cities and M roads connecting them. PP has measured the...
阅读全文
posted @ 2013-10-29 22:23
you Richer
阅读(218)
推荐(0)
摘要:
树链剖分 点权型可做模板,链路剖分的思想把点hash到线段树的上,然后可通过n*(log(n)*log(n))的复杂度在树上操作,在线段树上能操作的在链路上都能操作。#include#include#include#define M 40000#define lson (rt>1; build(l,mid,lson); build(mid+1,r,rson); push_up(rt); } void update(int ul,int new_flag,int rt){ if(e[rt].l==ul&&e[rt].r==ul)...
阅读全文
posted @ 2013-10-29 22:20
you Richer
阅读(238)
推荐(0)
摘要:
后缀自动机+dp。 后缀自动机主要是在functioner大牛那里学习的:http://blog.sina.com.cn/s/blog_70811e1a01014dkz.html 这道题是在No_stop大牛那里学习的:http://blog.csdn.net/no__stop/article/details/11784715特别感谢这两位大牛!贴上代码作为以后的模板吧。#include#include#include#include#include#define LL long long#define CLR(a, b) memset(a, b, sizeof(a))us...
阅读全文
posted @ 2013-10-29 22:19
you Richer
阅读(250)
推荐(0)
摘要:
Problem EOptimal Binary Search TreeInput:standard inputOutput:standard outputTime Limit:30 secondsMemory Limit:32 MBGiven a setS = (e1, e2, ..., en)ofndistinct elements such thate1#include #include using namespace std;int n, f[255], dp[255][255], sum[255];int main() { while (~scanf("%d", &
阅读全文
posted @ 2013-10-29 22:18
you Richer
阅读(196)
推荐(0)
摘要:
某赛车游戏,玩家可以选择不同的车,这些车其实是采用不同性能的配件组成的,如:车胎、发动机等。 玩家选择一部车,其实就是new了一部车。 你如何考虑“new car”的代码? 要new这个车,可能需要先new出车的各个配件,然后将这些配件组合成car。 某些复杂对象要new出来时,往往需要先new出它的子对象,然后组装成进父对象中,这些子对象有时候甚至组成了“树”结构。 生成器模式就是用来解决这问题的。 赛车游戏用生成器的解决方案: CAR_Builder定义了增加车组件的几个方法,还有CreateCar()方法。 BenZ_Builder类是具体生产奔...
阅读全文
posted @ 2013-10-29 22:16
you Richer
阅读(190)
推荐(0)
摘要:
The more, The BetterTime Limit: 6000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 4447Accepted Submission(s): 2643 Problem Description ACboy很喜欢玩一种战略游戏,在一个地图上,有N座城堡,每座城堡都有一定的宝物,在每次游戏中ACboy允许攻克M个城堡并获得里面的宝物。但由于地理位置原因,有些城堡不能直接攻克,要攻克这些城堡必须先攻克其他某一个特定的城堡。你能帮A...
阅读全文
posted @ 2013-10-29 22:13
you Richer
阅读(156)
推荐(0)
摘要:
赋值运算符 (一)JAVA种的赋值运算符 = ,代表代表的等于,一般的形式是 左边变量名称 = 右边的需要赋的指或者表达式,如果左侧的变量类型级别比较高,就把右侧的数据转换成左侧相同的高级数据,然后再复制给左边的变量。否则需要用强制类型转换。 int a,b,c; a = 13 ; b = 12 ; c = 12 ;int i = 10 ;//强制类型转换 byteb = (byte)i; /* a = b +c ; */ (二)复合赋值运算符 为了简化程序,提高的编译的效率,运算符前面可以加上不通的运算符,构成了复合赋值运算符。包括+=,-=,*=,/=,%=,>>...
阅读全文
posted @ 2013-10-29 22:12
you Richer
阅读(379)
推荐(0)
摘要:
1.在桌面点击安装完成的Domino 服务器配置:2.勾选Donimo Sever 以服务方式启动:3.在弹出的界面点击下一步继续配置:4.选择独立的Server 并点击下一步:5.填写相关的需要信息,这里的后点击下一步:6.填写组织名称需要的相应的信息,并点击Customize:7.这里如果你希望能够把服务器放入某个OU,则需要执行自定义步骤:8.填入网络域的名称:9.设定好系统账户和密码后点击下一步:10.选择需要启动的服务:11.在网络设定上选择自定义:12.填写好相关的信息:13.接受默认的权限设定:14.接下来进行相应的设定工作: 15.点击Finish 完成相关设定:16.在DNS
阅读全文
posted @ 2013-10-29 22:11
you Richer
阅读(126)
推荐(0)
摘要:
在J2EE框架下开发web网站,这种问题经常遇到,只要我们网上搜一下,就可以看到很多版本的,我整理一下: 第一种可能性解决:看看我的项目:主要 是里面的Structs 1.3 (structs 2)和Hibernate 3.2(或更高版本)中的JAR包里antlr2.7.2 与 antlr2.7.6 冲突,只要删除Structs 1.3中的低版本的antlr2.7.2就可以了。具体操作如下:在MyEclipse 下,windows-->preferences-->在文本框中搜索struts2-->选择 antlr2.7.2-->remove
阅读全文
posted @ 2013-10-29 22:06
you Richer
阅读(202)
推荐(0)
摘要:
背景:stanford的计算广告学(computational advertising)课程,yahoo的人主讲,课程链接:http://www.stanford.edu/class/msande239/#lecture-handouts,这个ppt使其中的一讲,93页 主要内容: 1.Display ad targeting: 相比于搜索广告来讲,搜索体现了明显的意图,显示广告,用户只有浏览行为,而浏览行为体现出的用户行为比起搜索行为差了好多,所以是“High entropy” of user intent。相比而言,显示广告的CRT...
阅读全文
posted @ 2013-10-29 22:05
you Richer
阅读(556)
推荐(0)
摘要:
双击Setup 安装:选择安装地点: 选择安装的组件:选择安装:在桌面双击相应的lotus admin,在弹出窗口中点击下一步:点击下一步继续设置:输入密码:取消及时信息并点击下一步: 点击继续后完成相关配置:我们打开Lotus测试邮件收发是否正常: 我们再回到Lotus admin:进入到惯常选项:选择注册选项,勾选为新用户创建ID:选择默认存放地点后点击确定: 接下来我们选择服务器验证的目录及ID,点击确定后退出惯常选项:我们最好将以下的这些ID 保存到其他的地方:
阅读全文
posted @ 2013-10-29 22:02
you Richer
阅读(135)
推荐(0)
摘要:
初始化sqlite3 (创建表) QString url = QDir::currentPath() + QString::fromLocal8Bit("/Msg.db"); bool isExsiting = false; QFileInfo file(url); if (!file.absoluteDir().exists()) { QDir dir; dir.mkpath(file.path()); } if (file.exists()) isExsiting = true; if(SQLITE_O...
阅读全文
posted @ 2013-10-29 22:01
you Richer
阅读(910)
推荐(0)
摘要:
比如www.hongchangfirst.com和video.hongchangfirst.com两个域名,一级域名相同,二级域名不同。每个服务器运行着不同的功能模块或者不同的子系统,他们使用不同的二级域名,但用户系统是统一的,即一套用户名、密码在整个网站的各个子系统中都是可以登录使用的。 解决这个问题很简单,只需要前后端配合就行。前端:set cookie的时候sessionid的domain设置为一级域名,domain=hongchangfirst.com 后端:使用数据库保存sessionid等相关内容,所有的服务器都去查询此数据库,所以保持了各个sessionid的一致性。 好了,就是
阅读全文
posted @ 2013-10-29 21:57
you Richer
阅读(422)
推荐(0)
摘要:
欧几里德算法:欧几里德就是辗转相除法,调用这个gcd(a,b)这个函数求解a,b的最大公约数公式:gcd(a,b)=gcd(b,a%b);并且gcd(a,b)=gcd(b,a)=gcd(-a,b)=gcd(|a|,|b|)代码:int gcd(int a,int b)//递归{ if(b==0) return a; return gcd(b,a%b);}int gcd(int a,int b)//递归简化{ return b ? gcd(b,a%b) : a;}int gcd(int a, int b)//迭代{ while(b != 0...
阅读全文
posted @ 2013-10-29 21:57
you Richer
阅读(207)
推荐(0)
摘要:
概要:计算HIVE BI库下每天数据表总大小及增量输出: 总大小:xxxG日同比新增数据量:xxxG周同比新增数据量:xxxG月同比新增数据量:xxxG总表数:xxx日新增表数:xxx周新增表数:xxx月新增表数:xxx最大的20张表:......表数据增量TOP20:......代码: bi_report.sh#!/bin/bashGIGA=1000000000content="\n"prefix='bi'today=`date -d"-1 day" +%Y-%m-%d`yestoday=`date -d"-2 day&quo
阅读全文
posted @ 2013-10-29 21:56
you Richer
阅读(1585)
推荐(0)