
c
iastro
这个作者很懒,什么都没留下…
展开
-
codeblocks gcc error: 'for' loop initial declarations are only allowed in C99 mode|
源代码#include #include int main(){ for(int i=0; i<1600; i=i+20) { int c; c = 5*(i-32)/9; printf("%d \t %d\n",i,c); } return 0;}使用gcc编译代码是报出error: 'for'原创 2015-03-14 22:38:38 · 3999 阅读 · 0 评论 -
codeblocks编译错误
问题1 ld.exe||cannot open output file bin\Debug\test.exe Permission denied|||=== Build finished: 1 errors, 0 warnings ===| 编译出现这个错误是什么原因答案: 新的数据无法写入\Debug\test.exe文件,这是因为原来的那个test.exe程序还在原创 2015-03-14 18:21:15 · 9101 阅读 · 0 评论 -
练5-4 习编写strend(s,t)函数。如果字符串t出现在字符串s的尾部,该函数返回1,否则返回0。
#include #include #include int strend(char *s, char *t){ int step = strlen(s) - strlen(t); char *pos = s + step; while(*pos++ == *t++) { if(*pos == '\0')原创 2015-04-26 18:46:02 · 5704 阅读 · 0 评论