上一页 1 ··· 41 42 43 44 45 46 47 48 49 ··· 53 下一页
摘要: #include int atoi(char s[])//转换的方法 { int i,n; n=0; for(i=0;s[i]>='0'&&s[i]<='9';++i) n=10*n+(s[i]-'0'); return n; } main() { int n=0,m=0; char s [10],s1[10]; ... 阅读全文
posted @ 2009-06-24 01:08 macula7 阅读(145) 评论(0) 推荐(0)
摘要: #include int atoi(char s[])//转换的方法 { int i,n; n=0; for(i=0;s[i]>='0'&&s[i]<='9';++i) n=10*n+(s[i]-'0'); return n; } main() { int n=0,m=0; char s [10],s1[10]; ... 阅读全文
posted @ 2009-06-24 01:08 macula7 阅读(981) 评论(0) 推荐(0)
摘要: int反映特定机器的自然大小,一般为16位或者32位 short一般为16位,long一般为32位 各个编译器可能不同,没有硬性规定,唯一的限制是short类型与int类型至少要有16位,而long类型至少32位。short对象不得长于int对象,int对象不得长于ling对象 singed用于限定数据是否有符号位。 \a 响铃符 \b 回退 \f 换页 \n 换行 \r 回车 \t 横向制表符 ... 阅读全文
posted @ 2009-06-24 00:54 macula7 阅读(92) 评论(0) 推荐(0)
摘要: int反映特定机器的自然大小,一般为16位或者32位 short一般为16位,long一般为32位 各个编译器可能不同,没有硬性规定,唯一的限制是short类型与int类型至少要有16位,而long类型至少32位。short对象不得长于int对象,int对象不得长于ling对象 singed用于限定数据是否有符号位。 \a 响铃符 \b 回退 \f 换页 \n 换行 \r 回车 \t 横向制表符 ... 阅读全文
posted @ 2009-06-24 00:54 macula7 阅读(110) 评论(0) 推荐(0)
摘要: #include main() { int c,i,nwhilte,nother; int ndigit[10]; nwhilte=nother=0; for(i=0;i='0'&&c<='9') ++ndigit[c-'0']; else if(c==' '||c=='\n'||c=='\t') ++n... 阅读全文
posted @ 2009-06-24 00:38 macula7 阅读(178) 评论(0) 推荐(0)
摘要: #include main() { int c,i,nwhilte,nother; int ndigit[10]; nwhilte=nother=0; for(i=0;i='0'&&c<='9') ++ndigit[c-'0']; else if(c==' '||c=='\n'||c=='\t') ++n... 阅读全文
posted @ 2009-06-24 00:38 macula7 阅读(222) 评论(0) 推荐(0)
摘要: 1:字符计数 #include main() { char c; double n=0; //注意可以使用double 类型 while((c=getchar())!=EOF) n++; printf("%.0f",n); } 2:行计数 #include main() { char c; int n=0; ... 阅读全文
posted @ 2009-06-24 00:27 macula7 阅读(147) 评论(0) 推荐(0)
摘要: 1:字符计数 #include main() { char c; double n=0; //注意可以使用double 类型 while((c=getchar())!=EOF) n++; printf("%.0f",n); } 2:行计数 #include main() { char c; int n=0; ... 阅读全文
posted @ 2009-06-24 00:27 macula7 阅读(173) 评论(0) 推荐(0)
摘要: #define 名字 替换文本 例子: #define LOWER 0 #define UPPER 300 #define STEP 20 阅读全文
posted @ 2009-06-24 00:06 macula7 阅读(123) 评论(0) 推荐(0)
摘要: #define 名字 替换文本 例子: #define LOWER 0 #define UPPER 300 #define STEP 20 阅读全文
posted @ 2009-06-24 00:06 macula7 阅读(149) 评论(0) 推荐(0)
上一页 1 ··· 41 42 43 44 45 46 47 48 49 ··· 53 下一页