题目:
Roman numerals come from the ancient Roman numbering system. They are based on specific letters of the alphabet which are combined to signify the sum (or, in some cases, the difference) of th...
分类:
其他好文 时间:
2014-06-20 12:27:09
阅读次数:
394
First-class Everything-- Guido van
RossumFirst-class object:
第一类对象。意指可在执行期创建并作为参数传递给其他函数或存入一个变量的对象。简而言之,第一类对象在使用时没有任何限制。第一类对象典型特征是可以动态创建、销毁,作为参数传递,可以作...
分类:
编程语言 时间:
2014-06-20 08:48:46
阅读次数:
287
先上用来生成Tree的JSON数据 [ { "id": "Root", "name":
"资源目录" }, { "id": "PF", "name": "批发价格", "parent": "Root" }, { "id": "PF93",
"name": "93#", "parent": "
分类:
其他好文 时间:
2014-06-13 13:49:33
阅读次数:
442
cocos2d-x
3.x版本变动比较大,从改用cmake管理整个项目,到使用python集成一体化的项目工具。这些都是我喜欢的,我可以很容易的在我的ubuntu上面搭建环境,而且根本就不用考虑IDE的事情,sublime-text
or emacs足矣。唯一需要自己动手的就是制作一个比较好的调试工...
分类:
其他好文 时间:
2014-06-12 00:57:11
阅读次数:
709
这两天处理模块的联调工作,在json与XML转换中出现了一些奇怪的问题,仔细究来,实为对org.json.*包知之太少。晚上baidu、google一下,找出了问题出现的原因。在模块中,使用了两个方法,xml2Json()和json2Xml(),主要的问题就出在这两个方法的具体实现上。XML与JSO...
分类:
Web程序 时间:
2014-06-11 23:53:35
阅读次数:
448
1.这种方式的问题是,只列出当前import进上下文的模块.进入python命令行.输入以下代码:>>>import
sys>>>sys.modules2.在python命令行下输入:>>>help()help>modules
分类:
编程语言 时间:
2014-06-11 23:18:22
阅读次数:
287
学习Python使用MYSQLdb操作MYSQL数据库...
分类:
数据库 时间:
2014-06-07 14:44:13
阅读次数:
256
python实现的链表,包括插入、查找、删除操作
#!/usr/bin/python
class linknode():
def __init__(self,k,n=None):
self.key=k;
self.next=n;
def createlist(): #创建链表
n=raw_input("enter the num of nodes");
n=int(...
分类:
编程语言 时间:
2014-06-07 12:23:46
阅读次数:
204
range用法
使用python的人都知道range()函数很方便,今天再用到他的时候发现了很多以前看到过但是忘记的细节。
这里记录一下:
>>>
range(1,5)
#代表从1到5(不包含5)
[1,
2,
3,
4]
>>>
range(1,5,2)
#代表从1到5,间隔2(不包含5)
[1,
3]
>...
分类:
编程语言 时间:
2014-06-07 12:09:21
阅读次数:
276