码迷,mamicode.com
首页 >  
搜索关键字:4th edition    ( 1650个结果
C - The C Answer (2nd Edition) - Exercise 1-10
/* Write a program to copy its input to its output, replacing each tab by \t, each backspace by \b, and each backslash by \\. This makes tabs and backspaces visible in an unambiguous way. */ #inclu...
分类:其他好文   时间:2015-07-12 20:25:20    阅读次数:93
C - The C Answer (2nd Edition) - Exercise 1-7
/* Write a program to print the value of EOF. */ #include main() { printf("EOF is %d\n", EOF); } /* Output: EOF is -1 */...
分类:其他好文   时间:2015-07-12 20:24:24    阅读次数:103
C - The C Answer (2nd Edition) - Exercise 1-8
/* Write a program to count blanks, tabs, and newlines. */ #include /* count blanks, tabs, and newlines */ main() { int c, nb, nt, nl; nb = 0; /* number of blanks */ nt = 0; /* number of t...
分类:其他好文   时间:2015-07-12 20:23:41    阅读次数:103
C - The C Answer (2nd Edition) - Exercise 1-9
/* Write a program to copy its input to its output, replacing each string of one or more blanks by a single blank. */ #include #define NONBLANK 'a' /* replace string of blanks with a single blank...
分类:其他好文   时间:2015-07-12 20:22:41    阅读次数:127
C - The C Answer (2nd Edition) - Exercise 1-6
/* Verify that the expression getchar() != EOF is 0 or 1. */ #include main() { int c; while(c = getchar() != EOF) { printf("%d\n", c); } printf("%d - at EOF\n", c); }...
分类:其他好文   时间:2015-07-12 19:02:18    阅读次数:145
C - The C Answer (2nd Edition) - Exercise 1-5
/* Modify the temperature conversion program to print the table in reverse order, that is, from 300 degrees to 0. */ #include /* print Fahrenheit-Celsius table in reverse order */ main() { int...
分类:其他好文   时间:2015-07-11 20:16:44    阅读次数:164
C - The C Answer (2nd Edition) - Exercise 1-4
/* Write a program to print the corresponding Celsius to Fahrenheit table. */ #include /* print Celsius-Fahrenheit table for celsius = 0, 20, ..., 300; floating-point version */ main() { float...
分类:其他好文   时间:2015-07-11 20:14:23    阅读次数:176
C - The C Answer (2nd Edition) - Exercise 1-1
/* Run the "hello, world" program on your system. Experiment with leaving out parts of the program to see what error messages you get. */ #include main() { printf("hello world\n"); }...
分类:其他好文   时间:2015-07-11 18:31:13    阅读次数:107
C - The C Answer (2nd Edition) - Exercise 1-2
/* Experiment to find out what happens when printf's argument string contains \c, where c is some character not listed above. */ #include main() { printf("hello world\y"); printf("hello wor...
分类:其他好文   时间:2015-07-11 18:27:26    阅读次数:137
C - The C Answer (2nd Edition) - Exercise 1-3
/* Modify the temperature conversion program to print a heading above the table. */ #include /* print fahrenheit-Celsius table for fahr = 0, 20, ..., 300; floating-point version */ main() { fl...
分类:其他好文   时间:2015-07-11 18:26:47    阅读次数:147
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!