1.常量 变量 自动类型推断 let age = 20 常量不可变 var num = 24 变量可变 num = 30 let count:Int = 2 Double(count) 类型转换 2.字符串 Swift的String操作比较复杂,经常转为oc 的NSString let name:S ...
分类:
编程语言 时间:
2016-04-06 11:24:32
阅读次数:
178
题目链接:http://poj.org/problem?id=2777 题意是有L个单位长的画板,T种颜色,O个操作。画板初始化为颜色1。操作C讲l到r单位之间的颜色变为c,操作P查询l到r单位之间的颜色有几种。 很明显的线段树成段更新,但是查询却不好弄。经过提醒,发现颜色的种类最多不超过30种,所 ...
分类:
其他好文 时间:
2016-04-05 22:51:10
阅读次数:
208
count()函数功能:统计表中中某个字段或所有记录个数,字段值为null的不做统计。 手册中解释: COUNT returns the number of rows returned by the query. You can use it as an aggregate or analytic ...
分类:
其他好文 时间:
2016-04-05 19:50:24
阅读次数:
151
初始化对象private Paint mPaint;//画笔
private int count;//点击次数
private Rect rect;//矩形
public CounstomView(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
//初始化画笔...
分类:
移动开发 时间:
2016-04-05 17:53:50
阅读次数:
470
(g_jvm)->AttachCurrentThread(&env, NULL) 后使用 (g_jvm)->DetachCurrentThread();程序报错 ERROR: detaching thread with interp frames (count=13) 在java线程中不能使用Att ...
分类:
其他好文 时间:
2016-04-05 16:04:34
阅读次数:
155
题目描述 输入一个整数,输出该数二进制表示中1的个数。其中负数用补码表示。 Solution 1: class Solution { public: int NumberOf1(int n) { bitset<32> bit(n); return bit.count(); } }; Solution ...
分类:
其他好文 时间:
2016-04-05 13:59:49
阅读次数:
84
1 public class CirculLinkedList 2 { 3 //元素个数 4 private int count; 5 6 //尾指针 7 private Node tail; 8 9 //当前节点的前节点 10 private Node CurrPrev; 11 12 13 //增 ...
分类:
其他好文 时间:
2016-04-05 13:53:27
阅读次数:
172
1452: [JSOI2009]Count Description Input Output Sample Input Sample Output 1 2 HINT Source Solution 忽略标题的说法...撞壁用的.... 简单题,裸树状数组套树状数组 颜色数目$c<=100$很小,考虑 ...
分类:
编程语言 时间:
2016-04-05 12:40:51
阅读次数:
246
内容页: <script src="{dede:field name='phpurl'/}/count.php?view=yes&aid={dede:field name='id'/}&mid={dede:field name='mid'/}"type='text/javascript' langu ...
分类:
其他好文 时间:
2016-04-05 12:12:14
阅读次数:
115