在iOS开发中,任何可见视图都是继承于UIView的。 继承体系中,大部分UIView的属性适用于其任何孩子。 而UIView的layer属性可以绘制UIView的各种效果。其实我们看到的View的动画实际上也是layer在绘制。1、绘制圆角 cornerView.layer.corn...
分类:
其他好文 时间:
2015-08-13 17:53:51
阅读次数:
125
状态压缩DP#include#includeconst int MOD=100000000;int dp[15][5000];int mapp[15][15];int main(){ int m,n; while(~scanf("%d%d",&m,&n)) { for...
分类:
其他好文 时间:
2015-08-08 22:48:06
阅读次数:
109
http://poj.org/problem?id=3254参考:http://blog.csdn.net/accry/article/details/6607703农夫想在m*n的土地上种玉米,但是有的土地很贫瘠,所以不能种,每块土地标为1的表示能种,标为0的表示不能种,并且种玉米的土地不能相邻,...
分类:
其他好文 时间:
2015-08-08 22:40:04
阅读次数:
170
这里是你想要的功能:支持插件,将你要执行的任务编译成程序集放到框架的根目录下,再进行简单的配置就行了。支持Corn表达式。想让任务在什么时候执行就在什么时候执行。支持安装成windows service (通过topshelf实现)保证任务在执行阶段,就算到了下一个触发时间,不重复执行(如果本次还没...
Corn FieldsTime Limit:2000MSMemory Limit:65536KTotal Submissions:9806Accepted:5185DescriptionFarmer John has purchased a lush new rectangular pasture ...
分类:
其他好文 时间:
2015-08-06 01:51:40
阅读次数:
215
一、枚举所有宽度为举着宽度的子矩阵,从中找出是否具有相应长度的正方形,复杂度为O(n^3);二、[1]中使用动态规划,decrease the complexity to O(n^2)dp[i][j] mean the maximum square which has right-down corn...
分类:
其他好文 时间:
2015-08-01 15:40:02
阅读次数:
108
题目链接:http://poj.org/problem?id=3254
题目意思:给你一个n*m的牧场,叫你带牛去吃草,其中0代表没有草不可以放牧,1代表有草可以放牧。而且两头牛不可以相邻,叫你求所有可能的放牧方案。
思路:这是个状态压缩的基础题,刚学状态压缩的可以用这个题目来理解状态压缩;(如果是刚学DP我建议理解题意后先粗略的看一下代码后再边看代码边看我的思路,效果更佳)
...
分类:
其他好文 时间:
2015-07-30 00:47:54
阅读次数:
133
Simplify Path
Given an absolute path for a file (Unix-style), simplify it.
For example,
path = "/home/", => "/home"
path = "/a/./b/../../c/", => "/c"
click to show corner cases.
Corn...
分类:
其他好文 时间:
2015-07-28 16:04:11
阅读次数:
125
Children of the Candy Corn
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 10975
Accepted: 4731
Description
The cornfield maze is a popular Halloween treat...
分类:
其他好文 时间:
2015-07-28 10:47:44
阅读次数:
103
Corn FieldsTime Limit:2000MSMemory Limit:65536KTotal Submissions:9623Accepted:5092DescriptionFarmer John has purchased a lush new rectangular pasture ...
分类:
其他好文 时间:
2015-07-26 14:07:01
阅读次数:
171