Validate if a given string is numeric.Some examples:
“0” => true
” 0.1 ” => true
“abc” => false
“1 a” => false
“2e10” => true
Note: It is intended for the problem statement to be ambiguous. You...
分类:
其他好文 时间:
2015-06-16 16:48:14
阅读次数:
103
IOS中CGAffineTransform的使用大概
CoreGraphics框架中的CGAffineTransform类可用于设定UIView的transform属性,控制视图的缩放、旋转和平移操作:
总得来说,这个类中包含3张不同类型,分别使用如下3个方法创建数值;
1.CGAffineTransformMakeTranslation(CGFloat tx, CGFloat ty)(平移...
分类:
移动开发 时间:
2015-06-14 16:47:53
阅读次数:
168
主要是简单的学习一下输出Hello world。跟了解 print 的用法,及#的作用#放在开头可以定义编码,如 #coding:gbk 指定编码为gbk#放在python代码中可以作为注释print "Hello world!"print "Hello Again"print "I like ty...
分类:
编程语言 时间:
2015-06-13 18:23:41
阅读次数:
154
dede导航下拉菜单,一级栏目增加二级下拉菜单使用dedecms5.6——5.7将这段代码贴到templets\default\head.htm文件里{dede:channelartlist typeid='top' cacheid='channelsonlist'}{dede:channel ty...
分类:
其他好文 时间:
2015-06-09 19:45:44
阅读次数:
118
比如ScrollView 知道它里面有个 View,其高度是 200,距离顶上为 55,但仅通过这两个约束没办法知道它的 contentSize 的高度是多少,我们缺少一个定义 View 到 ScrollView 底部距离的约束。...
分类:
其他好文 时间:
2015-06-08 13:34:49
阅读次数:
289
反汇编
wuyingqiang@ty-kf1:~/1$ gcc hello.c -o app
wuyingqiang@ty-kf1:~/1$ gcc hello.c -g -o app
-g参数决定反汇编之后的文件中,还能否看到c代码
wuyingqiang@ty-kf1:~/1$ objdump -dSsx app > file...
分类:
其他好文 时间:
2015-06-08 13:23:14
阅读次数:
145
简单的坐标变换:Quarzd 2D提供了三个API进行坐标变换://1.位移变换
CGContextTranslateCTM(CGContextRef c, CGFloat tx, CGFloat ty);对于变换后的坐标系而言,原点位于原坐标系的(tx,ty)处。也相当于在原有坐标系下,所有点的横纵坐标分别增加tx和ty。//2.旋转变换
CGContextRotateCTM(CGContextR...
分类:
其他好文 时间:
2015-06-06 18:13:25
阅读次数:
228
-2008 | -2002 | -93 | -87 choose VHDL 2008, 2002, 1993, or 1987-explicit resolve ambiguous overloads-work specify work library-check_synthesis ...
分类:
其他好文 时间:
2015-06-05 19:19:32
阅读次数:
115
//【C++】智能指针auto_ptr的简单实现
#include
using namespace std;
template
class auto_ptr
{
public:
auto_ptr(_Ty *_P = 0) :_Owns(_Ptr != 0), _Ptr(_P)
{}
auto_ptr(const auto_ptr &p):_Owns(p._Owns),_Ptr(...
分类:
编程语言 时间:
2015-06-05 17:32:36
阅读次数:
135
预处理语句修改数据函数$tn 表名,$data为修改要修改的数据,$w为条件function update($tn,$data=array(),$w='1=1'){ global $m; $ty = ''; foreach($data as $k=>$v){ $kk[] = $k.'=?'; $dd...
分类:
其他好文 时间:
2015-06-05 06:16:04
阅读次数:
125