摘要:
a.Python1.6 中只适用于Unicode 字符串,2.0 中适用于所有字符串b. 1.5.2 版本中string 模块没有该方法c. 在Jython2.1 有d. 仅对Unicode 字符串有效,e.Python2.5 或者以上版本string.capitalize() 把字符串的第一个字符大写string.center(width) 返回一个原字符串居中,并使用空格填充至长度width 的新字符串string.count(str, beg=0,end=len(string)) 返回str 在string 里面出现的次数,如果beg 或者end 指定则返回指定范围内str 出... 阅读全文
posted @ 2013-03-09 15:42
hacker_hzh
阅读(223)
评论(0)
推荐(0)
摘要:
超级水题 1 #include <stdio.h> 2 #include <stdlib.h> 3 #include <math.h> 4 int main() 5 { 6 int T, n; 7 8 scanf( "%d", &T ); 9 10 while( T -- )11 {12 scanf( "%d", &n );13 printf( "%d\n", ( int )( pow( 2, n ) - 1 ) );14 }15 return 0;16 } 阅读全文
posted @ 2013-03-09 13:23
hacker_hzh
阅读(103)
评论(0)
推荐(0)
摘要:
二维费用的背包。。。。。我的第一道背包啊啊啊啊啊 代码如下:::::(*^__^*) 嘻嘻 1 #include <stdio.h> 2 #include <stdlib.h> 3 #include <string.h> 4 5 int main() 6 { 7 int n, m, k, s, i, j, l; 8 int v[101], wi[101]; 9 int f[101][101];10 11 while( scanf( "%d%d%d%d", &n, &m, &k, &s ) != EOF )1 阅读全文
posted @ 2013-03-09 13:11
hacker_hzh
阅读(128)
评论(0)
推荐(0)

浙公网安备 33010602011771号