Pages--文档页面集合对象即指一堆页面的集合,可统计出当前文档有多少页面,可对页面集合进行插入页面操作,删除页面操作。属性:Count:当前页面集合中的页面个数。Item:获取指定索引的页面对象,索引值从0开始。方法:Add:插入一个指定高度、宽度、旋转角度的空白页面。Add..
分类:
其他好文 时间:
2014-08-29 16:18:38
阅读次数:
268
不同的面值Value[ ]有硬币个数Num[ ]限制,凑齐Goal面值,需要的最小和最大个数。
static int Min = 1<<10;
static int Max = 0;
static int* set;
static int* Count;
void LeastCoin_N(int* Value, int* Num, int Len, int Goal, int cur)...
分类:
其他好文 时间:
2014-08-29 13:08:17
阅读次数:
163
//move the repeated item NSInteger index = [orignalArray count] - 1; for (id object in [orignalArray reverseObjectEnumerator]) { if ([orignalArray ind...
分类:
其他好文 时间:
2014-08-29 12:47:57
阅读次数:
154
//如果有数据,选中第一行if(tableDataSource.count > 0) { NSIndexPath *indextPath = [NSIndexPath indexPathForRow:0 inSection:0]; // 调用UItableViewD...
分类:
其他好文 时间:
2014-08-29 12:23:57
阅读次数:
116
publicclassStringCount{
publicstaticvoidmain(String[]args){
Stringss="kkabkkcdkkefkkskk";
Stringkey="kk";
System.out.println(getSubCount_2(ss,key));
}
publicstaticintgetSubCount_2(Stringstr,Stringkey){
intcount=0;
intindex=0;
while((index=str.indexOf(key))..
分类:
编程语言 时间:
2014-08-29 11:15:28
阅读次数:
192
一表结构如下:MySQL5.5.305.6.20版本,表大概有815万行CREATETABLEt_audit_operate_log(Fidbigint(16)AUTO_INCREMENT,Fcreate_timeint(10)unsignedNOTNULLDEFAULT‘0‘,Fuservarchar(50)DEFAULT‘‘,Fipbigint(16)DEFAULTNULL,Foperate_object_idbigint(20)DEFAULT‘0‘,PRIMARYKEY(Fi..
分类:
数据库 时间:
2014-08-29 03:02:57
阅读次数:
332
一引子在MySQL的官方手册上有这么一句话:theoptimizercanestimatetherowcountforeachrangeusingdivesintotheindexorindexstatistics.这是在说:优化器为每一个范围段(如“aIN(10,20,30)”是等值比较,括3个范围段实则简化为3个单值,分别是10,20,30)估计每个范围段(用范围段来表..
分类:
数据库 时间:
2014-08-29 03:02:17
阅读次数:
287
1.一行代码实现值交换//a, ba = [b, b = a][0];2.三行代码实现分页逻辑//curr_index 当前页面//link_count 显示多少页//page_count 总页数start = Math.max(1, curr_index - parseInt(link_count...
分类:
其他好文 时间:
2014-08-28 19:37:05
阅读次数:
170
ultrawingrid 没有rows clear()功能自己写了一个等同的功能代码[c-sharp] view plaincopyprint?while(shredBatchGrid.Rows.Count>0){for(inti=0;i<=shredBatchGrid.Rows.Count-1;i...
冒泡排序法的基本思路就是,每经过一次循环,就把最大的交换到最后;到最后就成了一个从小到大的有序数组;小案例:从小到大,然后再从大到小;<?php
$arr1=array(1,-1,10,-9,0,3,7,-20,100);
functionSort1($arr){
for($i=0;$i<count($arr)-1;$i++){
for($j=0;$j<..
分类:
Web程序 时间:
2014-08-28 02:10:19
阅读次数:
233