码迷,mamicode.com
首页 > 其他好文
HDU-4841 圆桌问题 STL模拟约瑟夫问题
中文题,题意一看就是卧槽,这不约瑟夫么,然后脑子一抽就用了链表写,然后果然T了,最后用Vector模拟的约瑟夫问题。 #include #include #include #include #include #include #include #include #define LL __int64 using namespace std; int n,m; vectorp; in...
分类:其他好文   时间:2014-09-03 22:43:57    阅读次数:227
2014湘潭邀请赛 C题 湘大OJ 1205 Range (单调栈)
Problem Description For an array, the range function is defined below: Range(A)=Max(A)-Min(A)+1; For example, suppose A={1,2,3,4,5}, then Range(A)=5-1+1=5. Now, given an array A(length≤100000), you a...
分类:其他好文   时间:2014-09-03 22:42:27    阅读次数:266
xcode arc引起的autorelease报错问题
http://blog.csdn.net/xiechengfa/article/details/37971223自从用上了真苹果,一直升级,现在xcode版本是4.4,或者说是ios5一直有个问题,就是在release或者autorelease或者NSAutoreleasePool都报错原来是ios...
分类:其他好文   时间:2014-09-03 22:41:47    阅读次数:218
关于UIScrollView
UIScrollView1. contentOffset默认CGPointZero,用来设置scrollView的滚动偏移量。 // 设置scrollView的滚动偏移量 scrollView.contentOffset = CGPointMake(0, 200);2. contentSize默认C...
分类:其他好文   时间:2014-09-03 22:41:27    阅读次数:209
PostSharp 4.0注册机实现过程
PostSharp 4.0注册机实现过程
分类:其他好文   时间:2014-09-03 22:41:17    阅读次数:1737
8.8 冒泡排序 选择排序 二分查找 递归使用
冒泡排序:#include #include #include #define N 100000#define M 100000void show_arr(int * a,int n){ int i; for(i = 0; i a[j+1]) { temp = a[j]; a[j] = a[j+1]...
分类:其他好文   时间:2014-09-03 22:41:07    阅读次数:232
来自Neil
在写 migrate 的时候要考虑一些意外情况,比如: Comment.all , 如果有很多 comment ,而那个时候服务器内存又不够,那么很有可能就把内存给用光。所以foreach 操作很有必要。有些时候在 运行迁移的时候会出现,某个任务迁移到一半的时候,出现异常,迁移终止了。 这个时候该怎...
分类:其他好文   时间:2014-09-03 22:40:37    阅读次数:215
travel hamburg
The area west of Hamburg's central railway station is mainly a shopping area with the streets Spitaler Straße and Mönckebergstraße, leading to Hamburg...
分类:其他好文   时间:2014-09-03 22:39:47    阅读次数:516
hdu2896 AC自动机
病毒侵袭Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 11422Accepted Submission(s): 2957Problem Descr...
分类:其他好文   时间:2014-09-03 22:39:37    阅读次数:299
pvr与png的内存占用
Zwoptex生成的spritesheet除了可以导出png格式的图片外还有pvr格式。pvr格式是iOS的显示芯片可以直接读取的,不需要经过解析就能直接显示,所以渲染速度更快,更节省内存。我特意在cocos2D 2.0 rc1版本做了一项测试:一个空的cocos2D模版工程运行起来之后占用的内存大...
分类:其他好文   时间:2014-09-03 22:38:47    阅读次数:326
Something About Perl
Perl is a high-level , general-purpose,interpreted ,dynamic programming language . It was originally developed by Larry Wall in 1987 as a general-pur....
分类:其他好文   时间:2014-09-03 22:38:37    阅读次数:324
第四章 复合类型
第四章复合类型4.1数组 4.1.1数组简介 数组(array)是一种数据格式,能够存储多个同类型的值。 声明数组的通用格式如下: typeName arrayName[arraySize]; 表达式arraySize指定数组的元素数目,它只能是以下三种情况之一: 1)整型常数(如1...
分类:其他好文   时间:2014-09-03 22:38:07    阅读次数:370
将Canvas画布内容保存为jpg格式图片
/// /// 功能:将Canvas画布内容保存为jpg格式图片 /// 作者:GYS | 日期:2013年9月9日 /// /// /// private void SaveAsJpeg(string filePath, Canvas pixBox) { try { RenderTarge...
分类:其他好文   时间:2014-09-03 22:37:47    阅读次数:259
IP,路由,交换基础培训记录
IP,路由,交换基础培训记录:IP 掩码 子网划分 vlan划分(有助于减少广播压力) vlan之间互通通过交换机打通。路由,静态路由,动态路由(学习到的),路由表,下一跳,网络位长的优先级高。交换机,hub集线器。 hub是整体冲突模式,交换机是某个口是冲突模式。bps pps含义常用网络命令:p...
分类:其他好文   时间:2014-09-03 22:37:37    阅读次数:265
OS X 文档
显示Mac隐藏文件的命令:defaults write com.apple.finder AppleShowAllFiles YES隐藏Mac隐藏文件的命令:defaults write com.apple.finder AppleShowAllFiles NOdefaults write com....
分类:其他好文   时间:2014-09-03 22:37:27    阅读次数:225
LRTHW练习十
转义符表This all of the escape sequences Ruby supports. You may not use many of these, but memorize their format and what they do anyway. Try them out in ...
分类:其他好文   时间:2014-09-03 22:37:17    阅读次数:222
Selenium私房菜系列2 -- XPath的使用【ZZ】
在编写Selenium案例时,少不免是要用到XPath的,现在外面关于XPath使用的参考资料很多,下面我直接转一篇关于XPath使用的文档。如果对XPath不熟悉请参考下文,你不需要去百度/Google搜索关于XPath的资料,因为下面的内容已经足够你写测试时使用,如果你已熟悉XPath,本章大可...
分类:其他好文   时间:2014-09-03 22:37:07    阅读次数:338
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!