|
|
- 境 卢
- 7 years ago
- Views:
Transcription
1
2
3 C, Win-TC Turbo C,,
4 C, C,,,, C C, : Win-TC C, 23,,, 15,, C Turbo C Win-TC Turbo C,,,,
5 W in -TC 1 Win-TC 1 1. Win-TC 1 2. Win-TC 1 3. Win-TC 1 2 Win-TC HTML 5 3 Win-TC
6 Win-TC ASCII DOS / / / * * / LIB 19 6 Win-TC 21 C 1 Win-TC
7 23 50 C C Turbo C
8 W in -TC 1 Win-TC 1. Win-T C ( 1 ) Win-TC, : Pentium133 CPU 32MB ( 64MB, 4GB) 2 GB, 850MB Win98 /Win2000 / Win XP ( 2 ) Windows Win-TC18, 2. Win-T C ( 1 ) Win-TC : Win-TC : ( ) Win-TC ( 2 ) Win-TC : Win-TC : : Alt + F4 : : 3. Win-TC Win-TC, 1. 1
9 1. 1 Win-TC ( 1 ),, noname. c ( 2 ) Win-TC 5,, Win-TC 1. 2 ( 3 ) Win-TC, ( 4 ), Win-TC, ( 5 ), ( 6 ), ( 7 ),
10 Win-TC 1. 2 Win-TC 2 Win-TC 1. : : Ctrl + N : 2. 3 :
11 : Ctrl + O : 3. ( 1 ) : : Ctrl + S : ( 2 ) : 4. ( 1 ) : : ( 2 ) BGI ( ) : BGI : BGI 5. ( 1 ) Win-TC : : ( 2 ) Windows : Windows ( ) 6. ( 1 ) Win-TC :
12 Win-TC : ( 2 ) Windows : Windows ( ) 7. ( 1 ) Win-TC : : ( 2 ) Windows : Windows ( ) 8. ( 1 ) Win-TC : : ( 2 ) Windows : Windows ( ) 9. ( 1 ) Win-TC :... :... ( 2 ) Windows : Windows ( ) 10. HTML 5 : HTML
13 3 Win-TC 1. Win-TC,, ( 1 ) : ( ), ( ),,, ( 2 ) : ( ),, Shift ( ) :, Shift,,, ( 3 ) : Ctrl + A : :,, 2.,, : : : Ctrl + C : 3.,, :
14 Win-TC : : Ctrl + X : 4. ( ),, Del : 5.,, : : : Ctrl + P : 6. ( ), ( ), : ( ) : trl + F( ) : ( ) 7. ( ), ( ), : ( ) ( ) 7
15 : ( ) ( ) 8.,,, :, 9. ( ), Win-TC :
16 Win-TC ( 1 ) : : 3232, : 1616, Win-TC, : 4, : N, 0 N 4,, 0001, 1 Win-TC noname. c : Win-TC project noname. c : : Win-TC,, C : 99,, 999 :, ( pixel) ( 2 ) ( ) ( 3. 2 ), ; ( ) ; 9
17 3. 2 ( ) ( ) ,, Win-TC ( 3 ) ( 3. 3 ), VC, VC TAB, TAB ( TAB ) Win-TC,, 4
18 Win-TC 3. 3 ( 4 ) ( 3. 4 )
19 ,,. tpl, Win-TC, :,, 4 1. ( ),, ( ), ( obj ) ( exe ),,, : : F9 :, ;,,,, 4. 1 ; , ( exe ), : : Windows
20 Win-TC : : Win-TC : : Ctrl + F9 : 3., : 4., : 4. 3, 5, ( 1 ), 6 :, 64K,, CS = DS = SS = ES near.exe DOS EXE2 BIN.COM : 64K, 64K 13
21 4. 3, DS = SS = ES near : 64K, near 64K( 1M), far : 64K, far 64K, near, 64K, far : far, 1MB, 64K : far,,, Turbo C 64K, 64K
22 ( 2 ) : : : : ( 3 ) Win-TC Turbo C 2 Turbo C Turbo C 2 : Turbo C 2, Turbo C : Turbo C 2. 01, ( 4 ) FOR Turbo C 2 LIB LIB, LIB,, 10 LIB, LIB Win-TC ( 5 ) : / * * /, : / * aa / * bb * / cc * / :,, ASM,. exe. obj. exe, Obj : C. obj Map : C. map :, :,, / / : 15
23 :,, 5 Win-TC 1. ASCII Win-TC ASCII, ASCII ASCII : Alt + ASCII ASCII : ASCII ASCII ASCII
24 Win-TC 2. Win-TC,, EXE ( 5. 2 ),, DOS, 16 16, 6, : void drawmat( char * mat, int matsize, int x, int y, int color) / * : ( x, y) * / { nt i, j, k, n; n = ( matsize - 1) /8 + 1 ; for( j = 0; j < matsize; j + + ) for( i = 0; i < n; i + + ) for( k = 0; k < 8; k + + ) if( mat[ j* n + i] &( 0x80 > > k) ) / * 1 * / 17
25 putpixel( x + i* 8 + k, y + j, color) ; 3. DOS : CCDOS, PDOS95, Windows 98 PDOS95 DOS Windows 2000 Windows XP, PDOS95 DOS, UCDOS, Win-TC DOS, DOS DOS, DOS DOS,, EXE ( 5. 3 ) DOS,,, DOS,, DOS, 32 PE 16 NE,, DOS EXE 5. 3 DOS
26 Win-TC 4. / //* * / Win-TC C + +, / / Win- TC / / / /, #include / /, #include/ /,, / /, /* * / TC2 TC2, / // * * // / / * * /, TC2 5. LIB ( 1 ) Turbo C,, Win-TC, ( LIB) LIB FOR Turbo C FOR Visual C FOR Turbo C, (, *. h ) Win-TC include, *. lib lib, Win-TC, LIB,, ( 2 ) LIB LIB LIB? : ( OBJ) mylib / * * * * * mylib. c * * * * * / void myfun( ) { printf( \ nmyfun( ) in mylib. lib \ n ) ; Win-TC mylib. c OBJ,, 19
27 , ( F9 ) : LIB ( LIB) Win-TC mylib. obj Win-TC BIN, makelib. bat, : Tlib mylib. lib + mylib. obj, BIN mylib. lib : ( *. h) LIB BIN mylib. lib Win-TC lib mylib. lib,, : Win-TC, :void myfun( ) ;, #ifndef... #define... #endif, MYLIB, : #ifndef #define MYLIB MYLIB void myfun( ) ; #endif,, ( *. h), Win-TC INCLUDE,, mylib, INCLUDE mylib. h : LIB : #include mylib. h / * * / { yfun( ) ; getch( ) ; Ctrl + F9, : myfun( ) in mylib. lib, LIB
28 Win-TC 6 Win-TC ; ( ; ) ;, ; 1 Win 2000 Win XP Win-TC Win 2000 Win XP,,, getch( ), { printf( This is a TurboC. ) ; : { printf( This is a TurboC. ) ; getch( ) ;, :, 21
29 C 1 Win -TC 1. C 2. Win-TC 3. C 1. Win-TC, Win-TC 2. Win-TC 3. Win-TC, Win-TC 4. Win-TC 5. Win-TC 6. Win-TC 7. : #include stdio. h { printf( This is C program! ) ; ( 1 ) ( 2 ), ( 3 ), : I am a student! ( 4 ), : I am a student!
30 C 2 1. C 2. C 3. C 1. ( 1 ) printf( % d, 2 /3) ; ( 2 ) printf( % f, 2. 0 /3) ; ( 3 ) printf( % d, 2 /3* 100) ; ( 4 ) printf( % f, 2. 0 /3* 100) ; ( 5 ) printf( % d, 2 / ( 3* 100) ) ; ( 6 ) printf( % f, 2. / ( 3* 100) ) ; ( 7 ) printf( % d, 2. / ( 3* 100) ) ; ( 8 ) printf( % d, 2% 3) ; ( 9 ) printf( % d, 3% 2) ; ( 10) printf( % d, 3. 0% 2 ) ; 2. ( 1 ) = 3; j = 3 ; j = ( i + + ) + ( i + + ) + ( i + + ) ; printf( i = % d, j = % d, i, j) ; ( 2 ) = 3; j = 3 ; j = ( + + i) + ( + + i) + ( + + i) ; printf( i = % d, j = % d, i, j) ; ( 3 ) = 3; printf( a = % d \n, a) ; printf( a = % d \ n, a + + ) ; printf( a = % d \ n, + + a) ; 23
31 ( 4 ) printf( % d, ) ; ( 5 ) printf( % ld, ) ; ( 6 ) printf( % f, ) ; ( 7 ) printf( % 12. 4f, ) ; 3. ( 1 ) printf( % d, + + 4) ; ( 2 ) i = 3; j = 4 ; printf( % d, + + ( i + j) ) ; ( 3 ) i = 3; printf( % d, + + i + + ) ; ( 4 ) i = 3; printf( % d, i) ; ( 5 ) printf( % d, 5. 0% 3) ; ( 6 ) printf( % d, 5. 0% 3. 0) ; 4. ( 1 ) x = 4; x = 4 * 6, x* 5; x? ( 2 ) x = 4; x = ( 4* 6, x* 5 ) ; x? ( 3 ) a = 12; a + = a - = a* = a; a? ( 4 ) z = 7; z = 3 * z - - ; z? 5. ( 1 ) { nt i, j, m, n; i = 8; j = 10; m = i + + ; n = + + j; printf( % d, % d, % d, % d, i, j, m, n) ; 5 6 m = + + i; n = j + + ;? ( 2 ) define AMT a + a + a #define ATT AMT - AMT { nt a = 2; printf( % d, ATT) ;
32 C 3 1. C 2. printf( ) 3. scanf( ) 4. putchar( ) getchar( ) 1. : #include stdio. h { har m = 97, n; n = getchar( ) ; putchar( m) ; putchar( n) ; ( 1 ) ( 2 ) 1,? 2. : { nt a = - 1; printf( % d, a) ; printf( % u, a) ; ( 1 ) ( 2 ) a = - 2,?? 3. : { nt a = 20; 25
33 printf( % d, a) ; printf( % o, a) ; printf( % x, a) ; ( 1 ) ( 2 ) a = - 2,?? 4. : { nt a = 20; float b = ; printf( % - 5d#, % d* % 06. 2f, a, a, b) ; 5. : { nt a; float b; scanf( %, % d, a, b) ; printf( % d* % d, a, b) ; ( 1 ), ( 2 ) 4 : scanf( % o, % f, a, b) ;, 6. : { nt a, b; scanf( % 2d% * 3d% 2 d, &a, &b) ; printf( % d* % d, a, b) ; ( 1 ), , ( 2 ) 3 : scanf( % 3d% 3d, &a, &b) ;,?
34 C 1.,? 2. printf( ) scanf( ) if if... else ( 1 ) nt a; a = 5 > 3; printf( % d, a) ; ( 2 ) printf( % d,! 9) ; ( 3 ) nt a = 1, b = 2, c = 3, d = 4, m, n = 1; ( m = a > b) &&( n = c > d) ; printf( m = % d, n = % d, m, n) ; 2., { nt x = 1, y = 1, z = 1; y = y + z; x = x + y; printf( % d \ n, x < y? y: x) ; printf( % d \ n, x < y? x + + : y + + ) ; printf( % d \ n, x) ; printf( % d \ n, y) ; 27
35 x = 3; y = z = 4; printf( % d \ n, x > = y > = x? 1: 0) ; printf( % d \ n, z > = y&&y > = x) ; 3., ( 1 ) ain( ) { nt x; if x = 2) el e ( 2 ) ain( ) printf( all right! ) ; printf( it is wrong! ) ; { nt x; scanf( % d, &x) ; if( 2) else ( 3 ) ain( ) printf( all right! ) ; printf( it is wrong! ) ; { nt x = 3, y = 4, z = 5, ; if x < z) el e printf( % d, x + + ) ; if( y < z) else printf( % d, + + y) ; printf( % d, + + z) ; 4. ax 2 + bx + c = 0 : 1) a = 0,, x = - c / b ( 2) a = b = 0,
36 C ( 3) a0 : b 2-4ac > 0, ; b 2-4ac = 0, ; b 2-4ac < 0, 5. 3 a, b, c, : 1) a, b, c 0, ; ( 2), ; ( 3), ; ( 4) area = s( s - a) ( s - b) ( s - c), s = ( a + b + c) /2 6. : x 2-1, x < 0, y = 0, x = 0, x 2 + 1, x > 0, y, x 5 2 switch 1., { int x = 1, y = 0 ; switch( x) { case 1 : switch( y) { case 0 : rintf( * * 1* * \ n ) ; break; 29
37 , : case 1: printf( * * 2* * \n ) ; break; case 2: printf( * * 3 * * \ n ) ; 2.,, s s > 100, 95 ; s > 300, 90 ; s > 500, 80 ; s > 1 000, 75 ; s > 3 000, 70 switch( ) if... else..., 6 1 while( ) 1., { int a = 1, b = 2, c = 2, t; while( a < b < c) { t = a; a = b; b = t; c - - ; printf( % d, % d, % d, a, b, c) ; 2. m n, 3. s = 1! + 2! + 3! !
38 C 7 2 do... while( ) ) 1., { nt x = 0, y = 0 ; do { y + + ; x + = + + y; while( x < 18 ) ; printf( % d, % d, x, y) ; ( 3. s = n ( n = ) 8 3 for 1., { nt x = 1, y = 2, z = 3; for( ; < = 105; x + +, y + + ) 31
39 z = x* y* z; printf( % d, % d \n, x, y) ; 2. e, 10-6 e = /1! + 1 /2! / n! 3.,,, 128,,,,,,,,,,, 64,,,,,,, 1,,,,, C, 9 4 continue break 1. break, s = continue, , :,,,? 1. 2.?
40 C 3.,? 4.,? , #include stdio. h { nt i, c[ 5 ] ; int a[ ] = {9, 7, 5, 3, 1 ; int b[ ] = { - 2, - 4, - 6, - 8, - 10 ; f r( i = 0 ; i < 5; i + + ) c[ i] = a[ i] + b[ i] ; for( i = 0; i < 5 ; i + + ) printf( % 8d, c[ i] ) ; 2. 40, ( )
41 , #include stdio. h { nt a[ 3] [ 3] = {1, 2, 3, 4, 5, 6, 7, 8, 9, i, x = 0 ; for( i = 0; i < = 2 ; i + + ) x + = a[ i] [ i] ; printf( % d \ n, x) ; , (, ) 4. ( 9 ) :
42 C 2. 1., #include stdio. h { har a[ ] = { a, b, c, d, \0, x, y, z, \0 ; printf( % s, a) ; 2. #include stdio. h { har a[ 5 ], b[ 5] ; int i; for( i = 0; i < 5 ; i + + ) scanf( % c, a[ i] ) ; scanf( % s, b[ i] ) ; printf( % s\ n% s \n, a, b) ; 3. ( * ) * * * * * * * * * * * * * * * * * * * * * * * * *
43 1., #include stdio. h int fun1( ) { int x = 5; printf( % d \ t, x) ; return x; int fun2( int x) { printf( % d \ t, + + x) ; return x; { int x = 2; x = fun1( ) ; x = fun2( x) ; printf( % d \ n, x) ; 2.,, #include stdio. h { nt x = 4, y = 2 ; printf( % d \ n, mm( x* y) ) ; int mm( u, v) { int u, v; return( u* v) ; 3., f( x) = x 2 + 1, x > 1, x 2, - 1x1, x 2-1, x < - 1 double fun( double x)
44 C 4. ax 2 + bx + c = 0, b 2-4ac a, b, c 5. n! ( n = 10) n! = 1, n = 1, ( n - 1)!n, n > 1 6. n, : 1, n = 0, P n ( x) = x, n = 1, [ ( 2 n - 1) x - P n - 1 ( x) - ( n - 1) P n - 2 ( x) ] /n, n > , ( 1 ) include stdio. h void fun1( ) { nt x = 5; printf( % d \ t, x) ; void fun2( int x) { printf( % d \ t, + + x) ; { nt x = 2; fun1( ) ; fun2( x) ; 37
45 printf( % d \ n, x) ; ( 2 ) include stdio. h int x, y; { = 5 ; f( x) ; f( x) ; getch( ) ; int f( int x) { = x + + ; printf( % d \ n, y) ; ( 3 ) include stdio. h int x, y; { = 5 ; f( ) ; f( ) ; getch( ) ; int f( ) { = x + + ; printf( % d \ n, y) ; ( 4 ) include stdio. h int x, y; { = 5 ; f( x) ; f( x) ; getch( ) ; int f( ) { = x + + ; printf( % d \ n, y) ;
46 C ( 5 ) include stdio. h int x, y; { = 5 ; f( x) ; f( x) ; getch( ) ; int f( x) { = x + + ; printf( % d \ n, y) ; , #define MAX( a, b) ( ( a) > ( b)?( a) : ( b) ) 2., ( a) > ( b),?? 3., 4., f1. c, #define MAX( a, b) ( ( a) > ( b)?( a) : ( b) ) #include stdio. h 1, #include f1. c, 39
47 , 5., #define LETTER 1 { har str[ 20] = C language, c; int i; i = 0; while( ( c = str[ i] )! = \0 ) { i + + ; #if LETTER #else #endif printf( % c, c) ; if( c > = a &&c < = z ) c = c - 32; if( c > = A &&c < = Z ) c = c + 32; #include stdio. h { nt a; int * p; p = &a; scanf( % d, &a) ;
48 printf( % d \ n, a) ; C :, 2., #include stdio. h / * 3, * / { nt a, b, c; int * p1, * p2, * p3; scanf( % d, % d, % d, &a, &b, &c) ; p1 = &a; p2 = &b; p3 = &c; if( a > b) swap( p1, p2) ; if( a > c) swap( p1, p3) ; if( b > c) swap( p2, p3) ; printf( % d, % d, % d, a, b, c) ; swap( int * p1, int * p2) { nt x; ( 1 ), ( 2 ) : swap *,?? 3., #include stdio. h sub( int x, int y, int * z) { * z = y - x; { nt a, b, c; sub( 10, 5, &a) ; sub( 7, a, &b) ; sub( a, b, &c) ; printf( % 4d, % 4 d, % 4d \ n, a, b, c) ; 41
49 : int a[ 10] = {2, 4, 6, 8, 10, 12, 14, 16, 18, 20, i = 0; int * p; ( 1 ) p? ( 2 ) 2. p,? ( 1 ) * p; ( 2 ) * ( p + + ) ; ( 3 ) * p + + ; ( 4 ) * ( p + + ) * ( + + p), * ( p + + ) a [ i + + ]? 3. : 10,, { nt number[ 10 ] ; int * p, i; printf( input 10 numbers: ) ; fo ( i = 0 ; i < 10; i + + ) scanf( % d, &number[ i] ) ; maxminvalue( number) ; printf( New order: ) ;
50 C for( p = number; p < = number + 9; p + + ) printf( % d, * p) ; maxminvalue( int array[ 10] ) { nt * max, * min, * p, * end; end = array + 9; max = min = array; for( p = array + 1; p < = end; p + + ) if( * max < * p) max = p; * p = array[ 9] ; array[ 9] = * max; * max = * p; f r p = array + 1; p < = end; p + + ) if * min > * p) min = p; return; , 33, { nt a[ 3] [ 3], * p, i; printf( input matrix: \ n ) ; for( i = 0; i < 3 ; i + + ) scanf( % d% d% d, &a[ i] [ 1], &a[ i] [ 2 ], &a[ i] [ 3] ) ; p = &a[ 0] [ 0] ; 43
51 for( i = 0; i < 3 ; i + + ) for( j = 0; j < 3 ; j + + ) = * ( p + 3* i + j) ; * ( p + 3 * i + j) = * ( p + 3* j + i) ; * ( p + 3 * j + i) = t; printf( New matrix: \n ) ; for( i = 0; i < 3 ; i + + ) printf( % d% d% d \ n, a[ i] [ 0], a[ i] [ 1], a[ i] [ 2] ) ; 2., #include stdio. h #include string. h chnum( char * p) { nt num = 0 ; fo ( ; * p! = \0 ; p + + ) num = num* 10 + * p- 0 ; return( num) ; { har s[ 8 ] ;
52 C int n; gets( s) ; if( * s = = - ) n = - chnum( s + 1) ; else n = chnum( s) ; printf( % d \ n, n) ; ( 1 ) < >,? ( 2 ) 2345 < >,? 2. strcmp( ), #include stdio. h { nt n; char s1[ 10], s2[ 10 ] ; char * p, * q; printf( input 2 strings: \ n ) ; gets( s1) ; gets( s2) ; p = s1; q = s2; n = strcmp( p, q) ; printf( result: % d \n, n) ; nt strcmp( char * p, char * q) { nt i = 0, m; while( * ( p + i) = = * ( q + i) ) { f( break; i + + ; m = * ( p + i) - * ( q + i) ; return( m) ; ( 1 ) rechard < > rechard < >,? ( 2 ) rechard < > heland < >,? 45
53 ( 3 ) heland < > rechard < >,? ( 4 ), :, #include stdio. h stru t yymmdd { nt day; int month; int year; data; { nt days( int, int, int) ; int i, daysum; printf( please input year - month - day: ) ; scanf( % d, % d, % d, &data. year, &data. month, &data. day) ; daysum = days( data. year, data. month, data. day) ; printf( \ nthe dayth is % d \n, daysum) ; days( int year, int month, int day) / * * / { nt daysum, i; int tt[ 13 ] = {0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 ;
54 C daysum = 0; for( i = 1; i < month; i + + ) daysum = daysum + tt[ i] ; if( onth >= 3&&( year% 4 = = 0&&year% 100! = 0 year% 4 == 0) ) daysum + = 1; return( daysum) ; 2. : a b,, a b,, #include stdio. h struct ; tudent{ char num[ 10 ] ; float cj; struct student * next; { truct student a[ 4] = { { 001, 90, { 002, 85, 003, 91, { 004, 76 ; struct student b[ 5] = { { 005, 85, 006, 68, { 003, 91, int i, j; { 008, 64, { 007, 78 ; struct student * p, * p1, * p2, * pt, * head1, * head2 ; head1 = a; /* * / head2 = b; printf( list a: \ n ) ; for p1 = head1, i = 1; p1 < a + 4; i + + ) { = p1; p1 - > next = a + i; printf( % 8 s% 8. 1 f\ n, p1 - > num, p1 - > cj) ; p1 = p1 - > next; 47
55 p - > next = 0; printf( list b: \ n ) ; for p2 = head2, i = 1; p2 < b + 5; i + + ) { = p2; p2 - > next = b + i; printf( % 8 s% 8. 1 f\ n, p2 - > num, p2 - > cj) ; p2 = p2 - > next; printf( \ n ) ; p1 = head1; /* * / while( p1! = 0) { 2 = head2; while( p2! = 0&&strcmp( p1 - > num, p2 - > num)! = 0) p2 = p2 - > next; if strcmp( p1 - > num, p2 - > num) = = 0) if( p1 = = head1) head1 = p1 - > next; else p - > next = p1 - > next; p = p1 ; p1 = p1 - > next; p1 = head1; /* * / printf( \ n result: \ n ) ; while( { printf( % 8s% 8. 1f\ n, p1 - > num, p1 - > cj) ; 1 = p1 - > next;
56 C union study { nt i[ 2] ; x; float a; long b; char c; { canf( % d, % d, &x. i[ 0 ], &x. i[ 1 ] ) ; printf( i[ 0] = % d, i[ 1] = % d, a = % f, b = % ld, c = % c \ n, x. i[ 0], x. i[ 1], x. a, x. b, x. c) ; 1000, 2000, : scanf( % ld, &x. b) ; printf, 60000,??
57 ( : 16, 0) { nsigned int a, b; int n1, n2; printf( input a octal number: ) ; scanf( % o, &a) ; printf( input n1, n2 ) ; scanf( % d, % d, &n1, &n2) ; b = 0; b = ( b > > n1) &( b < < ( 16 - n2 ) ) ; b = a&b; b = b > > ( 16 - n2) ; printf( result: % o \n, b) ; < > 5, 10 < >, < > 5, 10 < >, : #include stdio. h
58 { ILE * p; char ch, filename[ 10] ; scanf( % s, filename) ; if ( p = fopen( filename, w ) ) = = NULL) { rintf( cannot open file \n ) ; exit( - 1 ) ; while( ( ch = getchar( ) )! = \ n ) fputc( ch, p) ; fclose( p) ; ( 1 ) head1. c < > ) welcome to c < > C ( ), ( 2 ) wr, while : while( ( ch = fgetc( p) )! = EOF) putchar( ch) ; head1. c < >, 2., 51
59 C 1 1. C ( ) ( ) ( ) 2. C ( ) ( ) ( ) 3. C ( ) 4. C ( ) 5. C ( ) 6. int a; a ( ) float x; x ( ) char u; u ( ) 7. C int ( ), float ( ), char ( ) 8. int x = 6;, x% 2 + ( x + 1) % 2 ( ) 9. int x;, x = 25 /3% 3 ( ) 10. int a = 6;, a + = a - = a* a ( ) 11. int a;, ( a = 4* 5, a* 2), a + 6 ( ) 12. int x, a;, ( 1) x ( ), ( 2 ) x ( ) ( 1 ) x = ( a = 4, 6* 2) ( 2) x = a = 4, 6* char ch;, ch = a ( 14. C ( ) 15. C ( ) 16. C ( ) 17. C, LEI lei ( ) ) 18. int float char ( ) ( )
60 ( ) ( ) ( C 19. int x;, scanf( % f, x) ; x, ( ) ( ) 20. int a, b scanf( ) ( ) 21. int a, b, 5, printf( ) ) 22. float x, y, 6, 2, printf( ) ( ) 1. C ( ) A) ) C) D) 2. ( ) A) A P 0 do B) float 1a0 A C) b - a goto int 3. ( ) A) 160-0xffff 011 B) - 0xcdf 01a 0xe C) ( ) D) 123 temp INT D) - 0x48a 2e5 A) + 1e + 1 B) C) 123e D) - e3 5e e e e e2-8e5 + 2e e ( ) A) \ \ \ \ n B) \ \017 \ 6. ( ) C) \018 \ f \ xab 0x D) \ \0 A) lei B) y + x C) minx. D) aax* 7. ( ) \101 \ x1f A) aaa B) ax1 C) 9 xx D) max 2 8. ( ) A) short a = 1 -. le - 1; B) double b = 1 + 5e2. 5; 53
61 C) long do = 0xfdaL; D) float 2 and = 1 - e - 3; 9. C, ( ) A) B), C) D) 10. ( ) A) x B) W C) D) XYZ 11. ( ) A) x B) ABC C) ABC D) C, ( ) A) + + B) / C) % D) * 13. int a = 5, y; y = a + + ;, a, y ( ) A) a = 6, y = 5 B) a = 6, y = 6 C) a = 6, y = 7 D) a = 5, y = C ( ) A) ( ) B) [ ] C) { D) 15. int k, a, b; unsigned long w = 5; double x = 1. 42;, C ( ) A) x% ( - 3 ) B) w + = - 2 C) k = ( a = 2, b = 3, a + b) D) a + = a - = ( b = 4) * ( a = 3) 16. int a = 7; float x = 2. 5, y = 4. 7 ;, x + a% 3 * ( int) ( x + y) % 2 /4 ( ) A) B) C) D) : char w; int x; float y; double z;, w* x + z - y ( ) A) float B) char C) int D) double 18. int, 7 ( ) A) ( x = y = 6, x + y, x + 1 ) B) ( x = y = 6, x + y, y + 1 ) C) ( x = 6, x + 1, y = 6, x + y) D) ( y = 6, y + 1, x = y, x + 1) 19. 3ae, C ( ) bc A) a / b / c* e* 3 B) 3 * a* e / b /c C) 3* a* e /b* c D) a* e /c / b* scanf( ) ( ) A) % f B) % u C) % o D) % c 21. int a, b = 5;, a ( )
62 A) = a; B) scanf( % d, &a) ; C) a = ( b + 6 ) /3; D) a = c ; 22. int a; &a ( ) A) B) a C) a D) 1. int a; a = 90000; 2. char c; c = y ; 3. int a, b; scanf( % D, % D, &a, &b) ; 4. int a = 10 ; float x = 1. 25; printf( % f, % d, a, x) ; 5. int i = j = k = 0; 1. ain( ) { nt x = 1, y = 1; 2. ain( ) x = x + y; y = x + y; printf ( x = % d y = % d \ n, x, y) ; { nt x = 7, a = 2, b = 2, c; c = x /a% b; printf( c = % d \n, c) ; 1., C 55
63 2., C = 5 9 ( F - 32) * / 3. a b, av, s1 s2 #include math. h / * sqrt( ), math. h 4., v 0 q g = 9. 8 s( s = 2v 2 0 sinqcosq / g) 2 1. A ASCII 65, ( ) { har ch1, ch2 ; ch1 = A ; ch2 = A ; printf( % d, % c \ n, ch1, ch2) ; A) 67, D B) 3, C C) C, D D)
64 C 2. ( ) { nt x = f ; printf( % c \n, A + ( x - a + 1) ) ; A) G B) H C) I D) J 3. ( ) # include < stdio. h > { nt a, b, d = 241; a = d /100% 9; b = ( - 1) * ( - 1) ; printf( % d, % d \ n, a, b) ; A) 6, 1 B) 2, 1 C) 6, 0 D) 2, 0 4. ( ) { ouble d = 3. 2 ; int x, y; x = 1. 2; y = ( x ) /5. 0; printf( % d \n, d* y) ; A) 3 B) 3. 2 C) 0 D) sizeof( double) ( ) A) B) C) D) 6. printf( a \bre \ hi \ y \ \ \ bou \ n ) ; ( ) A) a \ bre \ hi \ y \ \ \bou C) re hi you B) a \ bre \ hi \ y\ bou D) abre hi y \ bou 7., ( ) A) + + t; B) n1 = ( n2 = ( n3 = 0) ) ; C) k = i = = j; D) b + c = 1; 8. : int i = 65536; printf( % d \n, i) ; 57
65 ( ) ( ) A) B) 0 C), D) ( ) { nt x = 10, y = 3; printf( % d \n, y = x/ y) ; A) 0 B) 1 C) 3 D) 10. ( ) { nt a = 12, b = 12; printf( % d, % d \ n, a - -, b + + ) ; A) 11, 12 B) 12, 11 C) 12, 12 D) 11, ( ) { nt a = 12, b = 12; printf( % d % d \n, - - a, + + b) ; A) B) C) D) int x = 11;, ( x + +* 1 /3) ( ) A) 3 B) 4 C) 11 D) x int, x = 10 ; x + = x - = x - x;, x A) 10 B) 20 C) 40 D) x, y, z k int, x = ( y = 4, z = 16, k = 32), x ( ) A) 4 B) 16 C) 32 D) x y int, x = 100, y = 200, : printf( % d, ( x, y) ) ; ( ) A) 200 B) 100 C) D),
66 C 16. x y int, x + = y; y = x - y; x - = y; ( ) A) x y B) x y C) D) x y 3 1. ( ) { ouble d; float f; long l; int i; i = f = l = d = 20 /3; printf( % d % ld %. 1f %. 1 f\n, i, l, f, d) ; A) B) C) D) : 123 < > 456 < > 789 < >, ( ) { har s[ 100] ; int c, i; scanf( % c, &c) ; scanf( % d, &i) ; scanf( % s, s) ; printf( % c, % d, % s \ n, c, i, s) ; A) 123, 456, 789 B) 1, 456, 789 C) 1, 23, 456, 789 D) 1, 23, ( ) { nt k = 17; printf( % d, % o, % x \n, k, k, k) ; A) 17, 021, 0 x11 B) 17, 17, 17 C) 17, 0x11, 021 D) 17, 21, 11 59
67 4. ( ) { int k = 11; printf( k = % d, k = % o, k = % x \ n, k, k, k) ; A) k = 11, k = 12, k = 11 B) k = 11, k = 13, k = 13 C) k = 11, k = 013, k = 0xb D) k = 11, k = 13, k = b 5., a1, a2, c1, c2 10, 20, A, B,, ( int a1, a2; char c1, c2 ; scanf( % d% d, &a1, &a2) ; scanf( % c% c, &c1, &c2) ; A) 1020AB < > B) 0 20 < > AB < > ) ( ) C) AB < > D) AB < > 6., ( ) : float f1, f2; : A) scanf( % f, % f, &f1, &f2) ; B) scanf( % f% f, &f1, &f2 ) ; C) scanf( % 3. 2f % 2. 1 f, &f1, &f2) ; D) scanf( % 3. 2f% 2. 1f, &f1, &f2) ; 7., : 25, 13, 10 < >, ( ) { nt x, y, z; scanf( % d% d% d, &x, &y, &z) ; printf( x + y + z = % d \ n, x + y + z) ; A) x + y + z = 48 B) x + y + z = 35 C) x + z = 35 D) 8., ( )
68 C { nt x; float y; printf( enter x, y: ) ; enter x, y: x + y = A) canf( % d, % f, &x, &y) ; printf( \ nx + y = % 4. 2f, x + y) ; B) canf( % d% f, &x, &y) ; printf( \ nx + y = % 4. 2f, x + y) ; C) canf( % d% f, &x, &y) ; printf( \ nx + y = % 6. 1f, x + y) ; D) canf( % d% 3. 1 f, &x, &y) ; printf( \ nx + y = % 4. 2f, x + y) ; 4 ( 1. C, ( ), ( ) 2. C ( ), ( ) 3. ( ) 4. ( ) 5. ( ) 6. ) 7. a, b, : ( 1 ) a&&b ( ) ( 2 )! ( a b) &&a ( ) ( 3 )! a b ( ) ( 4 ) ( a&&! b) ( b&&! a) ( ) 8. int a, b, c;, a b c ( ) 9. int a, b, c;, a, b, c 0 ( ) < = x < = 100 x < ( ) 61
69 11. a, b, c, ( ), ( ) 12. int x = 5, y = 6, z = 1;, : ( 1 ) x + y && z ( ) ( 2 ) x + y > 8 && x - y > 1 ( ) ( 3 ) x + y > 8 x - y > 1 ( ) ( 4 ) z = = y > 0 ( ) ( 5 )! x < z ( ) > 3 && 2 8 < 4 -! 1 ( ) 14. int a = 1, b = 2;, ( a < b? a: b) ( ) 15. switch break ( ) 1. C, > = ( ) A) B) C) D) 2., ( ) A)! B) && C) + D) 3., ( ) A)! B) && C) + D) 4. int a = 2, b = 5;, a + 5 > b + 3 ( ) A) 0 B) 1 C) D) 5. : int a = 1, b = 2, c = 3, d = 4, m = 2, n = 2; : ( m = a > b) &&( n = c > d), n ( ) A) 1 B) 2 C) 3 D) 0 6. x, y, z, t int, x = y = z = 1; t = + + x + + y&& + + z;, t ( ) A) B) 2 C) 1 D) 0 7. a 0 ( ) A) a < > 0 B)! a C) a = 0 D) a! = 0 8. a10 a0 ( ) A) a > = 10 or a < = 0 B) a > = 10a < = 0 C) a > = 10a < = 0 D) a > = 10 &&a < = 0 9. int x = 1, y = 1;, (! x y - - ) ( )
70 C A) 0 B) 1 C) 2 D) a b ( ) A) ( a > = 0 b > = 0 ) &&( a < 0b < 0) B) ( a > = 0&&b > = 0) &&( a < 0&&b < 0) C) ( a + b > 0 ) &&( a + b < = 0) D) a* b > ( ) { nt x = 100, a = 10, b = 20, ok1 = 5, ok2 = 0 ; if( a < b) if b! = 15) if(! ok1) x = 1; el e if( ok2 ) x = 10; else x = - 1; printf( % d \ n, x) ; A) - 1 B) 0 C) 1 D) 12. a = 1, b = 3, c = 5, d = 4,, x ( ) if( a < b) if( c < d) x = 1; else f a < c) else x = 7; if( b < d) x = 2; else x = 3; else x = 6; A) 1 B) 2 C) 3 D) y = ( x > 0? 1: x < 0? - 1: 0 ) ; if ( ) A) f ( x > 0) y = 1; else f( x < 0) y = - 1; B) ( x) else y = 0; if( x > 0) y = 1; else f( x < 0) y = - 1; 63
71 C) = - 1 if x) D) = 0 ; else y = 0 ; if( x > 0 ) y = 1; else if( x = = 0 ) y = 0; else y = - 1; i ( x > = 0) i ( x > 0) y = 1; else y = - 1 ; 14. a = 1, b = 2, c = 3, d =4, a < b? a: c < d? a: d ( ) A) 4 B) 3 C) 2 D) char ch = A, ( ) ch = ( ch > = A &&ch < = Z )? ( ch + 32) : ch A) A B) a C) Z D) z 16. ( ) { nt x = 12, y; y = x > 12? x + 10: x - 12; printf( y = % d \ n, y) ; A) y = 0 B) y = 22 C) y = 12 D) y = switch, case ( ) A) B) C) D) 18. k 3, ( ) switch( k) { ase 1: putchar( A ) ; case 2: putchar( B ) ; case 3: putchar( C ) ; case 4: putchar( D ) ; default: putchar( E ) ; A) CDE B) C C) ABC D) ABCD
72 C 1. : a > b, c = 0; c = 1 int a = 1, b = 2, c; if( a > b) ; c = 0; else c = 1 ; 2. : a > b, a, b int a, b, c; scanf( % d, % d, &a, &b) ; if( a > b) c = a; a = b; b = c; 1. ain( ) { nt a = 1, b = 2, c = 3 ; if( a > c) 2. ain( ) b = a; a = c; c = b; printf( a = % d b = % d c = % d \ n, a, b, c) ; { nt a = 3, b = 2, c = 1 ; 3. ain( ) if( a > b) a = b; if( b > c) b = c; else c = b; c = a; printf( a = % d b = % d c = % d \ n, a, b, c) ; { nt x = 2, y = 3, z; z = x; if( x > y) z = 1 ; else if( x = = y) z = 0 ; else z = - 1; printf( z = % d \n, z) ; 65
73 4. ain( ) { nt a = 10, b = 5, x; x = a < b? b: a; printf( x = % d \n, x) ; , 10 5%, %, 2., 3., very good!, good!, fair, 0 39 poor
74 C 4. switch,, 90 A, B, C, D, 60 E 5 ( 1. while( ), ( ), ) 2. while, while ( ) 3. for( 1; 2; 3 ), ( ) 0 4. continue ( ) 5. break ( ) 6., 0 { nt a, max = 0; scanf( % d, &a) ; wh le( { f( max < a) max = a; scanf( % d, &a) ; printf( % d, max) ; 7., 67
75 #include stdio. h { har c; int n = 0 ; c = getchar( ) ; while( { f( n + + ; c = getchar( ) ; 8. or( a = 0, b = 0; b! = 100&&a < 5; a + + ) scanf( % d, &b) ; scanf ( ), ( ) 9. 30, 90, for x = 1 ; x < = 29; x + + ) { y = 30 - x; if( printf( % d, % d, x, y) ; { nt i, t = 1, s = 0; fo ( i = 1; i < = 101; i + = 2) { s = s + t* i; printf( % d, s) ; , 7, { nt i, a; for i = 1; i < = 10 ; i + + ) { s anf( % d, &a) ; if( a% 7 = = 0) { printf( % d, a) ;
76 C 1. ( ) A) B) C) D) 2. : int i; for( i = 0; i < = 10 ; i + + ) ;, i = 0, ( ) A) for B) C) for D) 3. ( ) A) do... while B) do... while break C) do... while, while D) do... while, while 4., ( ) { nt n = 0 ; while( n < = 2) { + + ; printf( % 3d, n) ; A) 1 B) 1 2 C) D) ( ) int a, y; a = 10; y = 0 ; do { + = 2; y + = a; printf( a = % d y = % d \ n, a, y) ; if( y > 20) break; while( a = 14) ; A) a = 12 y = 12 a = 14 y = 16 a = 16 y = 20 a = 18 y = 24 B) a = 12 y = 12 a = 16 y = 28 C) a = 12 y = 12 D) a = 12 y = 12 a = 14 y = 26 a = 14 y = 44 69
77 6. ( ) for( i = 1; i < = 3; i + + ) ; printf( ok ) ; A) ok B) okok C) okokok D) 7. ( ) int s = 7; while( - - s) ; s = s - 2; printf( s = % d \n, s) ; A) s = 1 B) s = 2 C) s = 0 D) s = ( ) a = - 1; do { a = a* a; while(! a) ; A) 1 B) 2 C) D) 9., 1, - 3, 5, 8, - 2, ( ) { nt i, x; for( i = 1; i < = 5 ; i + + ) { canf( % d, &x) ; if( x < = 0 ) continue; printf( % d, x) ; A) B) C) D) s = ( ) A) for( i = 1; i < = 5; i + + ) { s = 1 ; C) s = 1; s = s* i; for( i = 1; i < = 5; i + + ) s = s* i; 11. ( ) B) for( i = 1; i < = 5; i + + ) { s = 0; D) s = 0; s = s* i; for( i = 1; i < = 5; i + + ) s = s* i;
78 C ( ) for( i = 1; i < = 100; i + + ) { canf( % d, &x) ; if( x < 0) continue; printf( % d, x) ; A) x < 0 B) x0 C) printf( ) D) ( ) { nt k = 10; while( k = 0) { = k - 1; printf( k = % d, k) ; A) 10 B) while C) D) ( ) { nt k = 2; wh le( k! = 0) { rintf( k = % d, k) ; k - - ; A) B) 0 C) 2 D) 1 14., < >, main ( ) { nt m, n; printf( Enter m, n: ) ; scanf( % d% d, &m, &n) ; while( m! = n) { hile( m > n) m - = n; while( n > m) n - = m; printf( m = % d \ n, m) ; 71
79 A) m = 3 B) m = 2 C) m = 1 D) m = 0 15., ( ) A) int i = 100 while ( 1) {i = i% ; if( i > 100) break; B) for( ; ; ) ; C) int k =1000; do{ + + k while ( k > =1000) ; 16. for( i = 1; i + + < 4; ) ;, i ( ) D) int s =36 A) 3 B) 4 C) 5 D) 17. a b int, b ( ) a = 1; b = 10; do {b - = a; a + + ; while( b < 0) ; A) 9 B) - 2 C) - 1 D) 8 while( s) ; - - s; 18., 3, 0, ( 1),( 2) { ong int num; scanf( % ld, &num) ; do if( ( 1) ) printf( % ld, num) ; scanf( % ld, &num) ; while( ( 2 ) ) ; ( 1 ) ) num% 100 /10 = = 3 B) num /100 % 10 = = 3 C) num% 10 /10 = = 3 D) num/10% 10 = = 3 ( 2 ) A)! num B) num > 0 = = 0 C)! num = = 0 D)! num! = 0 1. s = s = 0 ; for( i = 1, i < = 5, i + + ) ; s = s + i;
80 C 2. s = s = 0 ; for( i = 1; i < = 5; i + + ) s = s* i; 1. ain( ) { nt x = 1, y = 1, i = 0; do 2. ain( ) { = x + y; y = x + y; i + + ; printf ( x = % d while( i < = 3) ; { nt x = 2, y = 10, i; 3. ain( ) for( i = x; i < = y; i + + ) ; printf( i = % d \ n, i) ; { nt x, y; 4. ain( ) y = % d \ n, x, y) ; fo ( y = 1, x = 1; y < = 50; y + + ) { f( x > = 10) break; if( x% 2 = = 1) { x + = 5; continue; x - = 3; printf( x = % d, y = % d \n, x, y) ; { nt j; fo ( j = 10; j > 3 ; j - - ) { f( j% 3) j - - ; 5. ain( ) j - = 2; printf( % 3d, j) ; 73
81 { nt x = 1, y = 0; switch( x) { ase : switch( y) 6. ain( ) { ase 0: printf( * * 1* * \ n ) ; break; case 1: printf( * * 2* * \ n ) ; break; case 2: printf( * * 3* * \n ) ; { nt x = 0, y = 0; 7. ain( ) while( x < 15) y + +, x + = + + y; printf( % d, % d, y, x) ; { nt i, sum = 0; 8. ain( ) for( i = 0 ; i < 3; i + + ) printf( % d % d \ n, i, sum + = i) ; { i t i; 9. ain( ) fo ( i = 1; i < = 5; i + + ) { f( i% 2 ) printf( * ) ; else continue; printf( # ) ; printf( \ n ) ; { i t i; fo ( i = 1; i < = 5; i + + ) sw tch( i% 2 ) { ase 0: i + + ; printf( # ) ; break; case 1: i + = 2 ; printf( * ) ; default: printf( \ n ) ;
82 C 1. n, 2. x, 0,, 3., : 50, 1. 5 ; 50, 0. 6, 5 150, , 75
83 6 1. int a[ 10] ;, a ( ), ( ) 2. int x[ 10] ;, x ( ), ( ), ( ), x ( ) 3. str Lei( ) 4. int a[ ] = {0, 1, 2, 3, 4, 5 ;, ( ) 5.,? ( ) 1. int a[ 10 ] ;, ( ) A) a( 9 ) B) a[ 9 ] C) a[ 10] D) a[ 3. 5] 2. ( ) A) int x[ 5] = {0, 1, 2, 3, 4, 5 ; B) int x[ ] = {0, 1, 2, 3, 4, 5 ; C) int x[ 5 ] = {0. 0 ; D) int x[ ] = ( 0, 1, 2, 3, 4, 5) ; 3. ( ) A) int x( 10) ; B) int x[ 5] = {0, 1, 2, 3, 4, 5 ; C) int n = 10; x[ n] ; D) int x[ ] = {0, 1, 2, 3, 4, 5 ; 4. a ( ) A) int a( 10) B) int n = 10, a[ n] ; C) int n; D) #define SIZE 10 scanf( % d, &n) ; int a[ SIZE] ; int a[ n] ; 5. ( ) A) int a[ 3] [ ] ; B) float a( 3, 4) ; C) double a[ 1] [ 4 ] ; D) float a( 3) ( 4) ; 6. : int a[ 3] [ 4] ;, ( ) A) a[ 2 ] [ 4 ] B) a[ 1, 3] C) a[ 1 + 1] [ 0] D) a( 2) ( 1) 7. ( ) A) int a[ 2] [ ] = { {1, 0, 1, {5, 2, 3 ;
84 C ( ) B) int a[ ] [ 3] = { {1, 2, 3, {4, 5, 6 ; C) int a[ 2 ] [ 4] = { {1, 2, 3, {4, 5, { 6 ; D) int a[ ] [ 3] = { {1, 0, 1 {, {1, 1 ; 8. ( ) A) ain( ) B) { loat a[ 10] = {0. 0 ; C) int i; D) for( i = 0; i < 3; i + + ) scanf( % d, &a[ i] ) ; E) for( i = 1; i < 10; i + + ) a[ 0] = a[ 0 ] + a[ i] ; F) printf( % f\ n, a[ 0 ] ) ; 9. str1, str2 ( ) A) if( str1 = = str2) ) if( if( str1 = str2 ) ) C) if( strcpy( str1, str2) ) D) if( strcmp( str1, str2 ) ) 10. : char array [ ] = China ;, array A) 4 ) 5 ) 6 ) ( ) { nt a[ 6], i; f r( i = 1; i < 6; i + + ) { [ i] = 9* ( i * ( i > 3) ) % 5; printf( % 2d, a[ i] ) ; A) B) C) D) s, ( ) A) char s[ 5] = { abc ; B) char s[ 5] = { a, b, c ; C) char s[ 5 ] = ; D) char s[ 5] = abcdef ; 13. ( ) char c[ 5] = { a, b, \0, c, \0 ; printf( % s, c) ; A) a b B) ab C) ab c D) abc 14. : char a[ ] = ABCDEF ; 77
85 char b[ ] = { ( ) A, B, C, D, E, F ; A) a b B) a b C) a b D) a b 15. : int i; int x[ 3 ] [ 3] = {1, 2, 3, 4, 5, 6, 7, 8, 9 ; ( ) for( i = 0; i < 3 ; i + + ) printf( % 2d, x[ i] [ 2 - i] ) ; A) B) C) D) , k ( ) int k = 3, s[ 2] ; s[ 0] = k; k = s[ 1] * 10 ; A) B) 33 C) 30 D) , Hello! b ( ) A) char b[ 10] = { H, e, l, l, o,! ; B) char b[ 10] ; b = Hello! ; C) char b[ 10] ; strcpy( b, Hello! ) ; D) char b[ 10] = Hello! ; 18. ( ) char a[ 7] = abcdef ; char b[ 4] = ABC ; strcpy( a, b) ; printf( % c, a[ 5] ) ; A) ( ) B) \0 C) e D) f 19. s1 s2, ( ) A) if( s1 > s2) B) if( strcmp( s1 > s2) ) C) if( strcmp( s2, s1) > 0 ) D) if( strcmp( s1, s2 ) > 0) 20. ( ) A) B) C) = D) 21. ( ) { char ch[ 7 ] = { 12ab56 ; int i, s = 0;
86 for( = 0; ch[ i] > = 0 &&ch[ i] < = 9 ; i + = 2) s = 10* s + ch[ i] - 0 ; printf( % d \ n, s) ; C A) 1 B) 1256 C) 12ab56 D) , int n; int a[ n] ; 2. a : { nt a[ 10], i; for( i = 1 ; i < 10; i + + ) scanf( % d, &a[ i] ) ; 1. ain( ) { nt a[ ] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, s = 0, i; 2. ain( ) for( i = 0 ; i < 10; i + + ) if( a[ i] % 2 = = 0) s = s + a[ i] ; printf( s = % d, s) ; { nt a[ ] = {1, 3, 5, 2, 7 ; 3. ain( ) int b[ ] = { 5, 3, 9, 4, 6 ; int c[ 5], i; f r( i = 0; i < 5; i + + ) c[ i] = a[ i] * b[ i] ; for( i = 0 ; i < 5; i + + ) printf( % d, c[ i] ) ; { nt i, k, a[ 10 ], p[ 3] : k = 5; for ( i = 0 ; i < 10; i + + ) a[ i] = i; 79
87 4. ain( ) { for ( i = 0 ; i < 3; i + + ) p[ i] = a[ i* ( i + 1) ] ; for ( i = 0 ; i < 3; i + + ) k = p[ i] * 2; printf( % d \n, k) ; int y = 18, i = 0, j, a[ 8 ] ; do { a[ i] = y% 2; i + + ; y = y /2; while( y > = 1) ; for( j = i - 1; j > = 0; j - - ) printf( % d, a[ j] ) ; printf( \ n ) , 2. n,,,,
88 C 3. n, m,,,, 7 1. ( ) ( ), ( ) ( ) 2., ( ) 3., ( ) 1. ( ) A) B) C) D), 2. ( ) A), B) return C), D), 3. ( ) A) B) C) D) 81
89 4., ( ) A) B) C) D) 5. ( ) A) double fun( int x, int y) B) double fun( int x; int y) C) double fun( int x, int y) ; D) double fun( int x, y) ; 6. ( ) A) ouble fun( int x, int y) { z = x + y; return z; C) un( x, y) { nt x, y; double z; z = x + y; return z; 7. ( ) B) un( int x, y) { nt z; return z; D) ouble fun( int x, int y) { ouble z; A) C z = x + y; return z; B) C, C) C D) C 8. ( ) A) B) C) D) 9. : fun( a + b, ( x, y), fun( n + k, d, ( a, b) ) ) ;, ( ) A) 3 B) 4 C) 5 D) ( ) #include stdio. h func( int a, int b) { nt c; c = a + b; return c;
90 C { nt x = 6, y = 7, z = 8, r; r = func( x - -, y + +, x + y), z) ; printf( % d \ n, r) ; A) 11 B) 20 C) 21 D) ( ) fun3( int x) { tatic int a = 3 ; a + = x; return( a) ; { nt k = 2, m = 1, n; n = fun3( k) ; n = fun3( m) ; printf( % d \ n, n) ; A) 3 B) 4 C) 6 D) static char str[ ] = Beijing ;, printf( % d \ n, strlen ( strcpy( str, China ) ) ) ; ( ) A) 5 B) 7 C) 12 D) , fun ( ) { in a[ 50], n; fun(, &a[ 9] ) ; A) void fun( int m, int x[ ] ) B) void fun( int s, int h[ 41 ] ) C) void fun( int p, int * s) D) void fun( int n, int a) 14. ( ) void func1( int i) ; void func2( int i) ; char st[ ] = hello, friend! ; 83
91 void func1( int i) { p intf( % c, st[ i] ) ; if( i < 3) { i + = 2; func2 ( i) ; void func2( int i) { rintf( % c, st[ i] ) ; if( i < 3 ) { i + = 2; func1( i) ; { nt i = 0; func1( i) ; printf( \ n ) ; A) hello B) hel C) hlo D) hlm 1. oid num( ) { xtern int x, y; int a = 15, b = 10 ; x = a - b; y = a + b; int x, y; { nt a = 7, b = 5; x = a + b; y = a - b; num( ) ; printf( % d, % d \ n, x, y) ; 2. unc( int a, int b) { tatic int m = 0, i = 2; i + = m + 1; m = i + a + b; return m;
92 C { nt k = 4, m = 1, p; p = func( k, m) ; printf( % d,, p) ; p = func( k. m) ; printf( % d \ n, p) ; 8 1. : #define N 3 #define Y( n) ( ( N + 1) * n) : z = 2* ( N + Y( ) ) ;, z ( ) A) B) 42 C) 48 D) ( ) #include stdio. h #define SUB( X, Y) ( X) * Y { nt a = 3, b = 4; printf( % d, SUB( a + +, b + + ) ) ; A) 12 B) 15 C) 16 D) ( ) #include stdio. h #define MIN( x, y) ( x) < ( y)? ( x) : ( y) { nt i, j, k; i = 10; j = 15; k = 10 * MIN( i, j) ; printf( % d \n, k) ; A) 15 B) 100 C) 10 D) , a ( ) #define SQR( X) X* X { nt a = 10, k = 2, m = 1; 85
93 a / = SQR( k + m) / SQR( k + m) ; printf( % d \n, a) ; A) 10 B) 1 C) 9 D) 0 5. ( ) #define MA( x) x* ( x - 1) { nt a = 1, b = 2; printf( % d \n, MA( 1 + a + b) ) ; A) 6 B) 8 C) 10 D) ( ) int fun( int x, int y, int * cp, int * dp) { cp = x + y; * dp = x - y; { nt a, b, c, d; a = 30; b = 50; fun( a, b, &c, &d) ; printf( % d, % d \ n, c, d) ; A) 50, 30 B) 30, 50 C) 80, - 20 D) 80, : int f( char * s) { har * p = s; while( * p! = \0 ) p + + ; return( p - s) ;, ( ) printf( % d \ n, f( goodbey! ) ) ;
94 C A) 3 B) 6 C) 8 D) 0 3. ( ) void prtv( int * x) { printf( % d \n, + + * x) ; { nt a = 25 ; prtv( &a) ; A) 23 B) 24 C) 25 D) ( ) int funl( char * x) { har * y = x; while( * y + + ) ; return( y - x - 1 ) ; A) B) C) x y D) x y 5. ( ) sss( s, t) char * s, * t; { hile( ( * s) &&( * t) &&( * t + + = = * s + + ) ) ; return( * ( - - s) - * ( - - t) ) ; A) B) C) s t D) s t 6. ( ) { nt i, x[ 3] [ 3] = {9, 8, 7, 6, 5, 4, 3, 2, 1, * p = &x[ 1] [ 1] ; for( i = 0 ; i < 4; i + = 2) printf( % 3d, * ( p + i) ) ; A) 5 2 B) 5 1 C) 5 3 D) : long int * p, a;, scanf ( ) 87
95 A) p = &a; scanf( % ld, p) ; B) = &a; scanf( % ld, p) ; C) scanf( % ld, p = &a) ; D) scanf( % ld, &a) ; 8. : char * st = how are you ;, ( ) A) har a[ 11 ], * p; strcpy( p = a + 1, &st[ 4] ) ; C) har a[ 11] ; strcpy( a, st) ; 9., ( ) { har * s = abcde ; s + = 2; printf( % ld \n, s) ; B) har a[ 11] ; strcpy( + + a, st) ; D) har a[ ], * p; strcpy( p = &a[ 1 ], st + 2) ; A) cde ) c ASCII ) c ) 10. : char str[ ] = ABCD, * p = str; printf( % d \ n, * ( p + 4) ) ; ( ) A) 68 B) 0 C) D D) 11. p1 p2 int, k int, ( ) A) k = * p1 + * p2; B) p2 = * k; C) p1 = p2; D) k = * p1 * ( * p2 ) ; 12. : int i, j = 7, * p = &i;, i = j; ( ) A) i = * p; ) * p = * &j; ) i = &j; ) i = * * p; 13. ( ) #include stdio. h #include string. h { har * p1 = abc, * p2 = ABC, str[ 50] = xyz ; strcpy( str + 2, strcat( p1, p2) ) ; printf( % s \ n, str) ;
96 C A) xyzabcabc B) zabcabc C) yzabcabc D) xyabcabc 14. ( ) { har a[ ] = programming, b[ ] = language ; char * p1, * p2; int i; p1 = a; p2 = b; fo ( i = 0; i < 7 ; i + + ) if * ( p1 + i) = = * ( p2 + i) ) printf( % c, * ( p1 + i) ) ; A) gm B) rg C ) or D) ga 15. x, pb, ( ) A) pb = &x B) pb = x; C) * pb = &x; D) * pb = * x 16. s ( ) char * s = \ \ Name \ \ Address \ n ; A) 19 B) 15 C) 18 D) 17. : int arr[ ] = {6, 7, 8, 9, 10 ; int * ptr; ( ) ptr = arr; * ( ptr + 2) + = 2; printf ( % d, % d \n, * ptr, * ( ptr + 2) ) ; A) 8, 10 B) 6, 8 C) 7, 9 D) 6, int( * ptr) [ m] ;, ptr ( ) A) m B) m C) m D) m, 19., ( ) A) char st[ 4] [ 5] = { ABCDE ; B) char s[ 5 ] = { A, B, C, D, E ; 89
97 C) char * s; s = ABCDE ; D) char * s; scanf( % s, s) ; 20. ( ) void func( int * a, int b[ ] ) { b[ 0] = * a + 6 ; { t a, b[ 5] ; a = 0; b[ 0] = 3; func( &a, b) ; printf( % d \ n, b[ 0] ) ; A) 6 B) 7 C) 8 D) ( ) int b = 2 ; int func( int * a) { + = * a; return( b) ; { nt a = 2, res = 2; res + = func( &a) ; printf( % d \ n, res) ; A) 4 B) 6 C) 8 D) ( ) { nt a[ 3] [ 3 ], * p, i; p = &a[ 0] [ 0] ; for( i = 0; i < 9; i + + ) p[ i] = i + 1; printf( % d \ n, a[ 1] [ 2] ) ; A) 3 B) 6 C) 9 D) 23. ( ) A) int * p; B) int * s, k; scanf( % f, p) ; * s = 100;
98 C C) int * s, k; D) int * s, k; char * p, c; char * p, c; s = &k; p = &c; s = &k; p = &c; * p = a ; s = p; * s = 500; 24. ( ) { har arr[ 2] [ 4] ; strcpy( arr, you ) ; strcpy( arr[ 1 ], me ) ; arr[ 0] [ 3] = & ; printf( % s \ n, arr) ; A) you&me B) you C) me D) arr ( ) #include stdio. h { nion { nt k; char i[ 2] ; * s, a; s = &a; s - > i[ 0] = 0x39 ; s - > i[ 1] = 0x38; printf( % x \n, s - > k) ; A) 3839 B) 3938 C) D) : typedef nion 91
99 struct { ong i; ate int k[ 5] ; char c; DATE; { nt cat; DATE max; DATE cow; double dog; too; ( ) printf ( % d, sizeof( struct date) + sizeof( max) ) ; A) 26 B) 30 C) 18 D) 8 3. ( ) A) #define printf C B) #define C, printf C) printf C, #define D) #define printf C 4. : ( struc st { nt n; struct st * next; ; static struct st a[ 3] = {5, &a[ 1 ], 7, &a[ 2 ], 9, \0, * p; p = &a[ 0] ; ) 6 A) p > n B) p - > n + + C) (* p). n + + D) + + p - > n 5. ( ) struct abc { int a, b, c; ; { truct abc s[ 2] = { {1, 2, 3, {4, 5, 6 ; int t; t = s[ 0]. a + s[ 1]. b; printf( % d \n, t) ; A) 5 B) 6 C) 7 D) 8 6., a ( )
100 union UVB { har st[ 4] ; ; int i; long l; struct A { nt c; a; union UVB u; A) 4 B) 5 C) 6 D) 8 7. int b = 2;, ( b > > 2) /( b > > 1) ( ) A) 0 B) 2 C) 4 D) 8 8. printf( % d \ n, 12&012) ; ( ) A) 12 B) 8 C) 6 D) 012 C 9. C, ( ) A) fprintf B) fread C) fwrite D) fputc C, ( ) A) \084 B) \ x43 C) ab D) \0 2. x y double, x = 1, y = x* 3 /2 ( ) A) 1 B) 2 C) 2. 0 D) , ( ) A) int a[ ] = string ; B) int a[ 5] = {0, 1, 2, 3, 4, 5 ; C) vhst s = string ; D) int a[ ] = {0, 1, 2, 3, 4, 5 ; 4. a, 15 < a < 100 ( ) A) a > 100 a < 15 B) a < 100&&a > 15 C) a > = 100 a < = 15 D) a < = 100&&a > = t double, t = 1, t + 5 ( ) A) 1 B) 6. 0 C) 2. 0 D) : 93
101 char s[ 10] ; s = abcd ; printf( % s \ n, s) ; ( ) ( ) A) abcd B) a C) abcd abcd D) 7. : int * * pp, * p, a = 10, b = 20 ; pp = &p; p = &a; p = &b; printf( % d \ n, * p, * * pp) ; ( ) A) 10, 20 B) 10, 10 C) 20, 10 D) 20, : int u = 010, v = 0 x10, w = 10; printf( % d, % d, % d \ n, u, v, w) ; ( ) A) 8, 16, 10 B) 10, 10, 10 C) 8, 8, 10 D) 8, 10, : char c1 = b, c2 = e ; printf( % d, % c \ n, c2 - c1, c2 - a + A ) ; ( ) A) 2, M B) 3, E C) 2, E D), 10. : char s[ 20] = programming, * ps = s; o ( ) A) ps2 B) s[ 2 ] C) ps[ 2 ] D) ps + 2, * ps 11. int i, j;, ( ) for( i = 5; i > 0; i - - ) for( j = 0; j < 4; j + + ) { A) 20 B) 25 C) 24 D) : char * s1 = 12345, * s2 = 1234 ; printf( % d \ n, strlen( strcpy( s1, s2) ) ) ; ( ) A) 4 B) 5 C) 9 D) : int a[ 10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, * p = a;
102 C a ( ) A) * p B) a[ 10] C) * a D) a[ p - a] 14. ( ) {c ar * s = 0121 ; int k = 0, a = 0, b = 0; do { + + ; if( k% 2 = = 0) { a = a + s[ k] - b = b + s[ k] - while( s[ k]! = \0 ) ; 0 ; continue; 0 ; a = a + s[ k] - 0 ; printf( k = % d a = % d b = % d \ n, k, a, b) ; A) k = 3 a = 2 b = 3 B) k = 3 a = 4 b = 2 C) k = 2 a = 4 b = 2 D) k = 2 a = 2 b = ( ) { nsigned a = ; printf( a = % d \ n, a) ; A) a = B) a = C) a = D) a = : float x; int a, b; switch ( ) A) switch( x) B) switch( x) { case 1. 0: printf( * \ n ) ; { case 1, 2: printf( * \n ) ; case 2. 0: printf( * * \ n ) ; case 3 : printf( * * \ n ) ; C) switch ( ab) D) switch ( ab) ; { case 1: printf( \ n ) ; { case 1: printf( * \n ) ; case 2: printf( * * \n ) ; case 2 : printf( * * \ n ) ; 17. : int x, y; char a, b, c; ( ) : 2 A B C x 1, y 2, a A, b B, c C ( ) 95
103 A) canf( x = % d y = % d, &x, &y) ; a = getchar( ) ; b = getchar( ) ; c = getchar( ) ; B) scanf( % d % d, &x, &y) ; a = getchar( ) ; b = getchar( ) ; c = getchar( ) ; C) scanf( % d% d% c% c% c, &x, &y, &a, &b, &c) ; D) scanf( % d% d% c% c% c% c% c% c, &x, &y, &a, &a, &b, &b, &c, &c) ; 18. ( ) #include stdio. h {c ar w[ ] [ 10] = { ABCD, EFGH, IJKL, MNOP ; int k; for ( k = 1; k < 3; k + + ) printf( % s \ n, &w[ k] [ k] ) ; A) ABCD B) ABCD C) EFG D) FGH FGH EFG JK KL KL IJ O M 19. : int a[ ] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, * p = a; 3 ( ) A) p = 2, * ( p) B) p = 2, * p C) p + = 3, * kp D) p + = 2, * p 20., x ( ) a = b = c = 0 ; x = 35; if! a) x - - ; e se if( b) x = 2 ; e se if( c) x = 3 ; else x = 4; A) 34 ) 4 ) 35 ) 3 21., ( ) A) < = B) = C) % D) && 22. : int w[ 2] [ 3], (* pw) [ 3] ; pw = w; w ( ) A) * ( w[ 0] 2) B) * ( pw1) [ 2 ] C) pw[ 0] [ 0] D) * ( pw[ 1] [ 2] )
104 C 23. : char str[ ] = ab \ n \012 \ \ \ ; printf( % d, strlen( str) ) ; ( ) A) 3 B) 4 C) 6 D) : strcat( strcpy( str1, str2), str3 ) ( ) A) str1 str2, str3 B) str1 str2, str3 C) str2 str1, str3 str1 D) str2 str1, str1 str3 25. C, ( ) A) C,, B) C, C), D) C 26. ( ) A) C,,, B) C, C) C, D) C, register 27. ( ) #include stdio. h subl( char a, char b) { char c; c = a; a = b; b = c; sub2 ( char* a, char b) { char c; c = * a; * a = b; b = c; sub3 ( char* a, char* b) { char c; c = * a; * a = * b; * b = c; { har a, b; a = A ; b = B ; sub3( &a, &b) ; putchar( a) ; putchar( b) ; a = A ; b = B ; sub2( &a, b) ; putchar( a) ; putchar( b) ; a = A ; b = B ; sub1( a, b) ; putchar( a) ; putchar( b) ; A) BABBAB B) ABBBBA C) BABABA D) BAABBA 28. : 97
105 struct sk {int a; float b; data, * p; p = &data;, data a ( ) A) ( * p). data. a B) ( * p). a C) p - > data. a D) p. data. a 29. ( ) A) enum a = {one, two, three ; B) enum a { one, two, three ; C) enum a = { one, two, three ; D) enum a { one, two, three ; 1. a C ( bc ) 2. a = 10, b = - 10,! a + b ( ) 3.,, ( ) 4. fun void, : #define M 50 { i t a[ M] ; fun( a) ; fun, : ( ), ( ), ( ) ( : q, ) 5. fun s : 6354abc, ( ) long fun( char s[ ] ) { ong n; int sign; for( ; isspace( * s) ; s + + ) ; sign = ( * s = = - )? - 11 ;
106 C if( * s = = - ) s + + ; for( n = 0 ; isdigit( * s) ; s + + ) n = 10* n + ( * s - 0 ) ; return ( sign* n) ; 6. w xw, n,, void fun ( char * w, char x, int * n) { nt i, p; p = 0; w[ * n] = x; wh le ( x > w[ p] ) ( ; for( i = * n; i > p; i - - ) w[ i] = ( ; w[ p] = x; * n + + ; 7. fun1 : fun1 ( &a, &b, &c) ;, a, b, c, a vo d fun2 ( int * x, int * y) { nt t; t = * x; * x = * y; * y = t; v id fun1 ( int * pa, int * pb, int * pc) { f( * pa < * pb) fun2( ; if( * pa < * pc) fun2 ( ; if( * pb < * pc) fun2( ; 1. ( ) A) C B) C) 12 D) 99
107 2. ( ) A) 5E2. 0 B) E - 3 C). 2E0 D) 1. 3E 3. ( ) A) long B) 2Test C) 3Dmax D) A. dat 4. A ASCII 65, a ASCII 97, \101 ( ) A) A B) a C) e D) 5. ( ) A) n = ( i = 2, + + i) ; B) j + + ; C) + + ( i + 1) ; D) x = j > 0 ; 6. a b double, a = 5. 5, b = 2. 5, ( int) a + b / b ( ) A) B) 6 C) D) i, j, k int, 1, 2, 3 < >, i 1, j 2, k 3, ( ) A) scanf( % 2d% 2d% 2d, &i, &j, &k) ; B) scanf( % d % d % d, &i, &j, &k) ; C) scanf( % d, % d, % d, &i, &j, &k) ; D) scanf( i = % d, j = % d, k = % d, &i, &j, &k) ; 8. 3xn C ( ) 2 x - 1 A) 3* x^n / ( 2* x - 1) B) 3* x* * n /( 2* x - 1) C) 3* pow( x, n) * ( 1 / ( 2* x - 1 ) ) D) 3* pow( n, x) / ( 2* x - 1) 9. : long x = L;, x ( ) A) printf( x = % d \ n, x) ; B) printf( x = % ld \n, x) ; C) printf( x = % 8dL \n, x) ; D) printf( x = % LD \n, x) ; 10. : { nt k = 2, i = 2, m; m = ( k + = i* = k) ; printf( % d, % d \ n, m, i) ; ( )
108 C A) 8, 6 B) 8, 3 C) 6, 4 D) 7, : int x = 3, y = 4, z = 5;,! ( x + y) + z - 1 &&y + z /2 ( ) A) 6 B) 0 C) 2 D) y = 1, x > 0, 0, x = 0, - 1, x < 0 x y ( ) A) if( x > 0) y = 1; else if( x = = 0) y = 0 ; else y = - 1; B) y = 0; if( x > 0) y = 1; else if( x < 0 ) y = - 1; C) y = 0; if( x > = 0) if( x > 0 ) y = 1; else y = - 1; D) if( x > = 0) if( x > 0 ) y = 1; else y = 0 ; else y = - 1; 13., k = n + + ( ) A) k = n, n = n + 1 B) n = n + 1, k = n C) k = + + n D) k + = n : 10 4,, : ain( ) { nt n, k; float score, sum, ave; sum = 0. 0; for( n = 1; n < = 10; n + + ) { o ( k = 1; k < = 4; k + + ) { scanf( % f, &score) ; sum + = score; ave = sum /4. 0 ; printf( NO% d: % f\ n, n, ave) ;, ( ) A) sum = 0. 0; B) sum + = score; C) ave = sum/4. 0; D) printf( NO% d: % f\ n, n, ave) ; 15. : int n = 0, p; 101
109 do { scanf( % d, &p) ; n + + ; while( p! = &&n < 3) ; do... while ( ) A) p n 3 B) p n 3 C) p n 3 D) p n : { nt a = 15, b = 21, m = 0; sw tch( a% 3) { ase 0: m + + ; break; case 1 switch( b% 2) { efault: m + + ; printf( % d \ n, m) ; ( ) ( ) case 0: m + + ; break; A) 1 B) 2 C) 3 D) C,, ( ) A) void B) int C) float D) double 18. : int n = 2, * p = &n, * q = p;, A) p = q; B) * p = * q; C) n = * q; D) p = n; 19. : float fun( int x, int y) { return( x + y) ; { nt a = 2, b = 5, c = 8; printf( % 3. 0f \n, fun( ( int) fun( a + c, b), a - c) ) ; ( ) A) 8 B) 9 C) 7 D) :
110 void fun( char * c, int d) { c = * c + 1 ; d = d + 1; printf( % c, % c,, * c, d) ; { har a = A, b = a ; fun( &b, a) ; printf( % c, % c \ n, a, b) ; ( ) A) B, a, B, a B) a, B, a, B C) A, b, A, b D) b, B, A, b C 13 : 1. sort a void sort( int a[ ], int n) { nt i, j, t; for( i = 0; i < n - 1; i + + ) for( j = i + 1 ; j < n; j + + ) if( a[ i] < a[ j] ) { t = a[ i] ; a[ i] = a[ j] ; a[ j] = t; { i t aa[ 10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, i; sort( &aa[ 3], 5) ; for( i = 0 ; i < 10; i + + ) printf( % d,, aa[ i] ) ; printf( \ n ) ; ( ) A) 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, B) 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, C) 1, 2, 3, 8, 7, 6, 5, 4, 9, 10, D) 1, 2, 10, 9, 8, 7, 6, 5, 4, 3, 2. : int f( int n) 103
111 { f ( n = = 1 ) return 1; else return f( n - 1) + 1; { nt i, j = 0 ; for( i = 1 ; i < 3; i + + ) j + = f( i) ; printf( % d \n, j) ; ( ) A) 4 B) 3 C) 2 D) 1 3. : { har a[ ] = { a, b, c, d, e, f, g, h, \0 ; int i, j; i = sizeof( a) ; j = strlen( a) ; printf( % d, % d \ n, i, j) ; ( ) A) 9, 9 B) 8, 9 C) 1, 8 D) 9, 8 4. reverse a : void reverse( int a[ ], int n) { nt i, t; for( i = 0 ; i < n /2; i + + ) { t = a[ i] ; a[ i] = a[ n i] ; a[ n i] = t; { nt b[ 10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ; int i, s = 0; reverse( b, 8) ; for( i = 6 ; i < 10; i + + ) s + = b[ i] ; printf( % d \n, s) ; ( ) A) 22 B) 10 C) 34 D) :
112 C { nt aa[ 4 ] [ 4] = { {1, 2, 3, 4, {5, 6, 7, 8, {3, 9, 10, 2, {4, 2, 9, 6 ; int i, s = 0; for( i = 0 ; i < 4; i + + ) s + = aa[ i] [ 1 ] ; printf( % d \n, s) ; ( ) A) 11 B) 19 C) 13 D) : #include string. h { har * p = abcde \0fghjik \0 ; printf( % d \n, strlen( p) ) ; ( ) A) 12 B) 15 C) 6 D) 5 7. type1. h : #define N 5 #define M1 N* 3 : #include type1. h #define M2 N* 2 { nt i; i = M1 + M2; printf( % d \ n, i) ; ( ) A) 10 B) 20 C) 25 D) : #include stdio. h { ILE * fp; int i = 20, j = 30, k, n; fp = fopen( d1. dat, w ) ; fprintf( fp, % d \ n, i) ; fprintf( fp, % d \n, j) ; 105
113 fclose( fp) ; fp = fopen( d1. dat, r ) ; fscanf( fp, % d% d, &k, &n) ; printf( % d% d \n, k, n) ; fclose( fp) ; ( ) : A) B) C) D) ( ) A), B), fclose C) fread, D) FILE 10. : #include string. h main( int argc, char * argv[ ] ) { nt i, len = 0; for( i = 1; i < argc; i + + ) len + = strlen( argv[ i] ) ; printf( % d \ n, len) ; ex1. exe ex1 abcd efg 10 < > ( ) A) 22 B) 17 C) 12 D) : int fa( int x) { return x* x; int fb( int x) { return x* x* x; int f( int ( * f1) ( ), int ( * f2) ( ), int x) { return f2 ( x) - f1( x) ; { nt i;
114 C i = f( fa, fb, 2) ; printf( % d \ n, i) ; ( ) A) - 4 B) 1 C) 4 D) : int a = 3 ; { nt s = 0 ; { int a = 5; s + = a + + ; s + = a + + ; printf( % d \ n, s) ; ( ) A) 8 B) 10 C) 7 D) : void ss( char * s, char t) { hile( * s) { f( * s = = t) * s = t - a + A ; s + + ; { har str1[ 100] = abcddfefdbd, c = d ; ss( str1, c) ; printf( % s \n, str1) ; ( ) A) ABCDDEFEDBD B) abcddfefdbd C) abcaafefaba D) Abcddfefdbd 14. : struct STU { char num[ 10] ; float score[ 3 ] ; { struct STU s[ 3] = { { 20021, 90, 95, 85, { 20022, 95, 80, 75, { 20023, 100, 95, 90, * p = s; int i; float sum = 0 ; for( i = 0 ; i < 3; i + + ) 107
115 sum = sum + p - > score[ i] ; printf( % 6. 2f\ n, sum) ; ( ) A) B) C) D) : struct sk { nt a; float b; data; int * p; p data a, ( ) A) p = &a; B) p = data. a; C) p = &data. a; D) * p = data. a 16. : #include stdlib. h struct NODE {int num; struct NODE * next; { truct NODE * p, * q, * r; p = ( struct NODE * ) malloc( sizeof( struct NODE) ) ; q = ( struct NODE * ) malloc( sizeof( struct NODE) ) ; r = ( struct NODE * ) malloc( sizeof( struct NODE) ) ; p - > num = 10 ; q - > num = 20; r - > num = 30 ; p - > next = q; q - > next = r; printf( % d \ n, p - > num + q - > next - > num) ; ( ) A) 10 B) 20 C) 30 D) : typedef int * INTEGER INTEGER p, * q; ( ) A) p int B) p int
1 2005 9 2005,,,,,,,,,, ( http: \ \ www. ncre. cn,, ) 30,,,,,,,, C : C : : 19 : 100081 : : 7871092 1 /16 : 8. 75 : 96 : 2005 11 1 : 2005 11 1 : ISBN 7
1 2005 9 2005,,,,,,,,,, ( http: \ \ www. ncre. cn,, ) 30,,,,,,,, C : C : : 19 : 100081 : : 7871092 1 /16 : 8. 75 : 96 : 2005 11 1 : 2005 11 1 : ISBN 7-80097 - 564-9 /TP 8 : 10. 00 ,,,, 1994 NCRE,,, ( ),,,,,
More information新版 明解C言語入門編
328, 4, 110, 189, 103, 11... 318. 274 6 ; 10 ; 5? 48 & & 228! 61!= 42 ^= 66 _ 82 /= 66 /* 3 / 19 ~ 164 OR 53 OR 164 = 66 ( ) 115 ( ) 31 ^ OR 164 [] 89, 241 [] 324 + + 4, 19, 241 + + 22 ++ 67 ++ 73 += 66
More informationC/C++ - 文件IO
C/C++ IO Table of contents 1. 2. 3. 4. 1 C ASCII ASCII ASCII 2 10000 00100111 00010000 31H, 30H, 30H, 30H, 30H 1, 0, 0, 0, 0 ASCII 3 4 5 UNIX ANSI C 5 FILE FILE 6 stdio.h typedef struct { int level ;
More information新・解きながら学ぶC言語
330!... 67!=... 42 "... 215 " "... 6, 77, 222 #define... 114, 194 #include... 145 %... 21 %... 21 %%... 21 %f... 26 %ld... 162 %lf... 26 %lu... 162 %o... 180 %p... 248 %s... 223, 224 %u... 162 %x... 180
More information新・明解C言語入門編『索引』
!... 75!=... 48 "... 234 " "... 9, 84, 240 #define... 118, 213 #include... 148 %... 23 %... 23, 24 %%... 23 %d... 4 %f... 29 %ld... 177 %lf... 31 %lu... 177 %o... 196 %p... 262 %s... 242, 244 %u... 177
More informationnooog
C : : : , C C,,, C, C,, C ( ), ( ) C,,, ;,, ; C,,, ;, ;, ;, ;,,,, ;,,, ; : 1 9, 2 3, 4, 5, 6 10 11, 7 8, 12 13,,,,, 2008 1 1 (1 ) 1.1 (1 ) 1.1.1 ( ) 1.1.2 ( ) 1.1.3 ( ) 1.1.4 ( ) 1.1.5 ( ) 1.2 ( ) 1.2.1
More informationCC213
: (Ken-Yi Lee), E-mail: feis.tw@gmail.com 49 [P.51] C/C++ [P.52] [P.53] [P.55] (int) [P.57] (float/double) [P.58] printf scanf [P.59] [P.61] ( / ) [P.62] (char) [P.65] : +-*/% [P.67] : = [P.68] : ,
More informationC 1
C homepage: xpzhangme 2018 5 30 C 1 C min(x, y) double C // min c # include # include double min ( double x, double y); int main ( int argc, char * argv []) { double x, y; if( argc!=
More information( CIP) /. :, ( ) ISBN TP CIP ( 2005) : : : : * : : 174 ( A ) : : ( 023) : ( 023)
( CIP) /. :, 2005. 2 ( ) ISBN 7-5624-3339-9.......... TP311. 1 CIP ( 2005) 011794 : : : : * : : 174 ( A ) :400030 : ( 023) 65102378 65105781 : ( 023) 65103686 65105565 : http: / /www. cqup. com. cn : fxk@cqup.
More informationプログラムの設計と実現II
UNIX C ls mkdir man http://www.tj.chiba-u.jp/lecture/prog2/ Ctrl+x, Ctrl+s ( )..[4]% gcc Wall o hoge hoge.c..[5]%./hoge 1 : 1 2 : 2 3 : 3 4 : 0 6..[6]% (! )..[4]% gcc Wall o hoge hoge.c..[5]%!g gcc Wall
More informationFY.DOC
高 职 高 专 21 世 纪 规 划 教 材 C++ 程 序 设 计 邓 振 杰 主 编 贾 振 华 孟 庆 敏 副 主 编 人 民 邮 电 出 版 社 内 容 提 要 本 书 系 统 地 介 绍 C++ 语 言 的 基 本 概 念 基 本 语 法 和 编 程 方 法, 深 入 浅 出 地 讲 述 C++ 语 言 面 向 对 象 的 重 要 特 征 : 类 和 对 象 抽 象 封 装 继 承 等 主
More information_汪_文前新ok[3.1].doc
普 通 高 校 本 科 计 算 机 专 业 特 色 教 材 精 选 四 川 大 学 计 算 机 学 院 国 家 示 范 性 软 件 学 院 精 品 课 程 基 金 青 年 基 金 资 助 项 目 C 语 言 程 序 设 计 (C99 版 ) 陈 良 银 游 洪 跃 李 旭 伟 主 编 李 志 蜀 唐 宁 九 李 涛 主 审 清 华 大 学 出 版 社 北 京 i 内 容 简 介 本 教 材 面 向
More informationC/C++ - 函数
C/C++ Table of contents 1. 2. 3. & 4. 5. 1 2 3 # include # define SIZE 50 int main ( void ) { float list [ SIZE ]; readlist (list, SIZE ); sort (list, SIZE ); average (list, SIZE ); bargragh
More information新版 明解C++入門編
511!... 43, 85!=... 42 "... 118 " "... 337 " "... 8, 290 #... 71 #... 413 #define... 128, 236, 413 #endif... 412 #ifndef... 412 #if... 412 #include... 6, 337 #undef... 413 %... 23, 27 %=... 97 &... 243,
More informationC/C++ - 字符输入输出和字符确认
C/C++ Table of contents 1. 2. getchar() putchar() 3. (Buffer) 4. 5. 6. 7. 8. 1 2 3 1 // pseudo code 2 read a character 3 while there is more input 4 increment character count 5 if a line has been read,
More informationC/C++语言 - C/C++数据
C/C++ C/C++ Table of contents 1. 2. 3. 4. char 5. 1 C = 5 (F 32). 9 F C 2 1 // fal2cel. c: Convert Fah temperature to Cel temperature 2 # include < stdio.h> 3 int main ( void ) 4 { 5 float fah, cel ;
More informationPs22Pdf
C ( CIP) C /. :, 2001. 7 21 ISBN 7-5624 -2355-5. C........ C. TP312 CIP ( 2001 ) 034496 C * * : 7871092 1 /16 : 14. 25 : 356 20017 1 20017 1 : 1 6 000 ISBN 7-5624-2355-5 / TP311 : 21. 00 C, C,,,, C,, (
More informationPs22Pdf
( 98 ) C ( ) ( )158 1998 C : C C C,,, C,, : C ( ) : : (, 100084) : : : 7871092 1/ 16 :18 25 :415 : 2000 3 1 2000 3 1 : ISBN 7 302 01166 4/ T P432 : 00016000 : 22 00 ( 98 ) 20 90,,, ;,,, 1994, 1998, 160,
More informationC/C++ - 字符串与字符串函数
C/C++ Table of contents 1. 2. 3. 4. 1 char C 2 char greeting [50] = " How " " are " " you?"; char greeting [50] = " How are you?"; 3 printf ("\" Ready, go!\" exclaimed John."); " Ready, go!" exclaimed
More informationC/C++程序设计 - 字符串与格式化输入/输出
C/C++ / Table of contents 1. 2. 3. 4. 1 i # include # include // density of human body : 1. 04 e3 kg / m ^3 # define DENSITY 1. 04 e3 int main ( void ) { float weight, volume ; int
More informationCC213
: (Ken-Yi Lee), E-mail: feis.tw@gmail.com 177 [P179] (1) - [P181] [P182] (2) - for [P183] (3) - switch [P184] [P187] [P189] [P194] 178 [ ]; : : int var; : int var[3]; var 2293620 var[0] var[1] 2293620
More informationC/C++ 语言 - 循环
C/C++ Table of contents 7. 1. 2. while 3. 4. 5. for 6. 8. (do while) 9. 10. (nested loop) 11. 12. 13. 1 // summing.c: # include int main ( void ) { long num ; long sum = 0L; int status ; printf
More information6 C51 ANSI C Turbo C C51 Turbo C C51 C51 C51 C51 C51 C51 C51 C51 C C C51 C51 ANSI C MCS-51 C51 ANSI C C C51 bit Byte bit sbit
6 C51 ANSI C Turbo C C51 Turbo C C51 C51 C51 C51 C51 C51 C51 C51 C51 6.1 C51 6.1.1 C51 C51 ANSI C MCS-51 C51 ANSI C C51 6.1 6.1 C51 bit Byte bit sbit 1 0 1 unsigned char 8 1 0 255 Signed char 8 11 128
More informationC C
C C 2017 3 8 1. 2. 3. 4. char 5. 2/101 C 1. 3/101 C C = 5 (F 32). 9 F C 4/101 C 1 // fal2cel.c: Convert Fah temperature to Cel temperature 2 #include 3 int main(void) 4 { 5 float fah, cel; 6 printf("please
More informationC
C 14 2017 5 31 1. 2. 3. 4. 5. 2/101 C 1. ( ) 4/101 C C ASCII ASCII ASCII 5/101 C 10000 00100111 00010000 ASCII 10000 31H 30H 30H 30H 30H 1 0 0 0 0 0 ASCII 6/101 C 7/101 C ( ) ( ) 8/101 C UNIX ANSI C 9/101
More information四川省普通高等学校
四 川 省 普 通 高 等 学 校 计 算 机 应 用 知 识 和 能 力 等 级 考 试 考 试 大 纲 (2013 年 试 行 版 ) 四 川 省 教 育 厅 计 算 机 等 级 考 试 中 心 2013 年 1 月 目 录 一 级 考 试 大 纲 1 二 级 考 试 大 纲 6 程 序 设 计 公 共 基 础 知 识 6 BASIC 语 言 程 序 设 计 (Visual Basic) 9
More informationint *p int a 0x00C7 0x00C7 0x00C int I[2], *pi = &I[0]; pi++; char C[2], *pc = &C[0]; pc++; float F[2], *pf = &F[0]; pf++;
Memory & Pointer trio@seu.edu.cn 2.1 2.1.1 1 int *p int a 0x00C7 0x00C7 0x00C7 2.1.2 2 int I[2], *pi = &I[0]; pi++; char C[2], *pc = &C[0]; pc++; float F[2], *pf = &F[0]; pf++; 2.1.3 1. 2. 3. 3 int A,
More informationC/C++ - 数组与指针
C/C++ Table of contents 1. 2. 3. 4. 5. 6. 7. 8. 1 float candy [ 365]; char code [12]; int states [50]; 2 int array [6] = {1, 2, 4, 6, 8, 10}; 3 // day_mon1.c: # include # define MONTHS 12 int
More informationC/C++语言 - 分支结构
C/C++ Table of contents 1. if 2. if else 3. 4. 5. 6. continue break 7. switch 1 if if i // colddays.c: # include int main ( void ) { const int FREEZING = 0; float temperature ; int cold_ days
More informationPowerPoint プレゼンテーション
Perl CGI 1 Perl CGI 2 Perl CGI 3 Perl CGI 4 1. 2. 1. #!/usr/local/bin/perl 2. print "Content-type: text/html n n"; 3. print " n"; 4. print " n"; 3. 4.
More informationC
C 2017 3 14 1. 2. 3. 4. 2/95 C 1. 3/95 C I 1 // talkback.c: 2 #include 3 #include 4 #define DENSITY 62.4 5 int main(void) 6 { 7 float weight, volume; 8 int size; 9 unsigned long letters;
More informationepub 33-8
8 1) 2) 3) A S C I I 4 C I / O I / 8.1 8.1.1 1. ANSI C F I L E s t d i o. h typedef struct i n t _ f d ; i n t _ c l e f t ; i n t _ m o d e ; c h a r *_ n e x t ; char *_buff; /* /* /* /* /* 1 5 4 C FILE
More information. (A) (B) (C) A (D) (E). (A)(B)(C)(D)(E) A
. () () () () () (A) (B) (C) B (D) (E). (A) (B) (C) E (D) (E) (A) (B) (C) (D). () () () () E (A) (B) (C) (D) (E). C (A) (B) (C) (D) (E). (A) (B) (C) (D) D (E). () - () - () - () - () - D (A) (B) (C) (D)
More informationC/C++语言 - 运算符、表达式和语句
C/C++ Table of contents 1. 2. 3. 4. C C++ 5. 6. 7. 1 i // shoe1.c: # include # define ADJUST 7. 64 # define SCALE 0. 325 int main ( void ) { double shoe, foot ; shoe = 9. 0; foot = SCALE * shoe
More information2015年计算机二级(C语言)模拟试题及答案(四)
2016 年 计 算 机 二 级 (C 语 言 ) 模 拟 试 题 及 答 案 (4) 一 填 空 题 1 C 语 言 中 基 本 的 数 据 类 型 有 : 2 C 语 言 中 普 通 整 型 变 量 的 类 型 说 明 符 为, 在 内 存 中 占 字 节, 有 符 号 普 通 整 型 的 数 据 范 围 是 3 整 数 -35 在 机 内 的 补 码 表 示 为 4 执 行 下 列 语 句 int
More informationC/C++ - 结构体、共用体、枚举体
C/C++ Table of contents 1. 2. 3. 4. 5. 6. 7. 8. 1 C C (struct) C 2 C C (struct) C 2 i // book.c: # include < stdio.h> # define MAX_ TITLE 41 # define MAX_ AUTHOR 31 struct book { char title [ MAX_ TITLE
More informationMicrosoft Word - 第3章.doc
Java C++ Pascal C# C# if if if for while do while foreach while do while C# 3.1.1 ; 3-1 ischeck Test() While ischeck while static bool ischeck = true; public static void Test() while (ischeck) ; ischeck
More information内 容 提 要 指 针 持 久 动 态 内 存 分 配 字 符 串 ( 字 符 数 组 ) 2
第 六 讲 指 针 与 字 符 串 1 内 容 提 要 指 针 持 久 动 态 内 存 分 配 字 符 串 ( 字 符 数 组 ) 2 指 针 什 么 是 指 针 指 针 的 定 义 与 运 算 指 针 与 一 维 数 组 指 针 数 组 行 指 针 与 二 维 数 组 指 针 与 引 用 指 针 与 函 数 3 指 针 定 义 什 么 是 指 针 指 针 变 量, 简 称 指 针, 用 来 存 放
More informationuntitled
串 串 例 : char ch= a ; char str[]= Hello ; 串 列 ch=getchar(); scanf( %c,&ch); 串 gets(str) scanf( %s,str); 8-1 數 ASCII 例 : char ch= A ; printf( %d,ch); // 65 A ascii =0x41 printf( %c,ch); // A 例 : char ch;
More informationuntitled
不 料 料 例 : ( 料 ) 串 度 8 年 數 串 度 4 串 度 數 數 9- ( ) 利 數 struct { ; ; 數 struct 數 ; 9-2 數 利 數 C struct 數 ; C++ 數 ; struct 省略 9-3 例 ( 料 例 ) struct people{ char name[]; int age; char address[4]; char phone[]; int
More information3.1 num = 3 ch = 'C' 2
Java 1 3.1 num = 3 ch = 'C' 2 final 3.1 final : final final double PI=3.1415926; 3 3.2 4 int 3.2 (long int) (int) (short int) (byte) short sum; // sum 5 3.2 Java int long num=32967359818l; C:\java\app3_2.java:6:
More information2 12
SHENZHEN BRILLIANT CRYSTAL TECHNOLOGIC CO.,LTD. The specification for the following models Graphic LCM serial communication control board CB001 PROPOSED BY APPROVED Design Approved TEL:+86-755-29995238
More information立 志 于 打 造 最 贴 近 考 生 实 际 的 辅 导 书 计 算 机 考 研 之 数 据 结 构 高 分 笔 记 率 辉 编 著 周 伟 张 浩 审 核 讨 论 群 :15945769
立 志 于 打 造 最 贴 近 考 生 实 际 的 辅 导 书 计 算 机 考 研 之 数 据 结 构 高 分 笔 记 率 辉 编 著 周 伟 张 浩 审 核 讨 论 群 :15945769 前 言 在 计 算 机 统 考 的 四 门 专 业 课 中, 最 难 拿 高 分 的 就 是 数 据 结 构 但 是 这 门 课 本 身 的 难 度 并 不 是 考 生 最 大 的 障 碍, 真 正 的 障 碍
More informationuntitled
MODBUS 1 MODBUS...1 1...4 1.1...4 1.2...4 1.3...4 1.4... 2...5 2.1...5 2.2...5 3...6 3.1 OPENSERIAL...6 3.2 CLOSESERIAL...8 3.3 RDMULTIBIT...8 3.4 RDMULTIWORD...9 3.5 WRTONEBIT...11 3.6 WRTONEWORD...12
More informationuntitled
A, 3+A printf( ABCDEF ) 3+ printf( ABCDEF ) 2.1 C++ main main main) * ( ) ( ) [ ].* ->* ()[] [][] ** *& char (f)(int); ( ) (f) (f) f (int) f int char f char f(int) (f) char (*f)(int); (*f) (int) (
More informationuntitled
1-1 1-2 1-3 1-4 1-5 1-6 1-7 1-8 1-1-1 C int main(void){ int x,y,z; int sum=0; double avg=0.0; scanf("%d",&x) ; scanf("%d",&y) ; scanf("%d",&z) ; sum=x+y+z ; avg=sum/3.0; printf("%f\n",avg); system("pause");
More information1 Project New Project 1 2 Windows 1 3 N C test Windows uv2 KEIL uvision2 1 2 New Project Ateml AT89C AT89C51 3 KEIL Demo C C File
51 C 51 51 C C C C C C * 2003-3-30 pnzwzw@163.com C C C C KEIL uvision2 MCS51 PLM C VC++ 51 KEIL51 KEIL51 KEIL51 KEIL 2K DEMO C KEIL KEIL51 P 1 1 1 1-1 - 1 Project New Project 1 2 Windows 1 3 N C test
More informationMicrosoft Word - CPE考生使用手冊160524.docx
大 學 程 式 能 力 檢 定 (CPE) 考 生 使 用 手 冊 2016 年 5 月 24 日 這 份 手 冊 提 供 給 參 加 CPE 檢 定 考 試 的 考 生 內 容 包 含 考 試 環 境 的 使 用, 以 及 解 題 時 所 使 用 I/O 的 基 本 知 識 1. 如 欲 報 名 參 加 CPE 考 試, 請 先 於 CPE 網 站 完 成 帳 號 註 冊, 然 後 再 報 名 該
More information但 洋 糖 最 终 乘 船 溯 江 而 上, 再 加 上 民 国 初 年 至 抗 战 前 夕 二 十 余 年 间, 四 川 接 连 不 断 遭 受 水 灾 旱 灾 地 震, 平 均 每 月 爆 发 两 次 军 阀 混 战, 乡 村 遭 受 极 大 破 坏,( 赵 泉 民,2007) 农 村 经 济
原 载 黄 宗 智 主 编 : 中 国 乡 村 研 究 ( 第 八 辑 ), 福 州 : 福 建 教 育 出 版 社 2010 年 4 月 第 一 版, 第 196-241 页 北 京 联 合 大 学 李 安 平 抗 战 时 期 四 川 内 江 农 贷 个 案 研 究 摘 要 : 抗 日 战 争 时 期 四 川 内 江 蔗 农 在 承 受 高 利 贷 盘 剥 的 严 酷 境 遇 中, 利 用 中 国
More information第5章修改稿
(Programming Language), ok,, if then else,(), ()() 5.0 5.0.0, (Variable Declaration) var x : T x, T, x,,,, var x : T P = x, x' : T P P, () var x:t P,,, yz, var x : int x:=2. y := x+z = x, x' : int x' =2
More informationMicrosoft PowerPoint - 20-string-s.pptx
String 1 String/ 1.: char s1[10]; char *s2; char s3[] = "Chan Tai Man"; char s4[20] = "Chan Siu Ming"; char s5[]={'h','e','l','l','o','\0'; 0 1 2 3 4 5 6 7 8 9 10 11 12 s3 C h a n T a i \0 M a n \0 printf
More information数据结构与算法 - Python基础
Python 教材及课件 课件及作业见网址 xpzhang.me 1 1. Python 2. 3. (list) (tuple) 4. (dict) (set) 5. 6. 7. 2 Python Python 3 Python 4 Python 1, 100, -8080, 0,... 0x 0-9, a-f 0 xff00, 0 xa432bf 5 1.24, 3.14, -9.80,...
More information全国计算机技术与软件专业技术资格(水平)考试
全 国 计 算 机 技 术 与 软 件 专 业 技 术 资 格 ( 水 平 ) 考 试 2008 年 上 半 年 程 序 员 下 午 试 卷 ( 考 试 时 间 14:00~16:30 共 150 分 钟 ) 试 题 一 ( 共 15 分 ) 阅 读 以 下 说 明 和 流 程 图, 填 补 流 程 图 中 的 空 缺 (1)~(9), 将 解 答 填 入 答 题 纸 的 对 应 栏 内 [ 说 明
More informationuntitled
3 C++ 3.1 3.2 3.3 3.4 new delete 3.5 this 3.6 3.7 3.1 3.1 class struct union struct union C class C++ C++ 3.1 3.1 #include struct STRING { typedef char *CHARPTR; // CHARPTR s; // int strlen(
More information, 7, Windows,,,, : ,,,, ;,, ( CIP) /,,. : ;, ( 21 ) ISBN : -. TP CIP ( 2005) 1
21 , 7, Windows,,,, : 010-62782989 13501256678 13801310933,,,, ;,, ( CIP) /,,. : ;, 2005. 11 ( 21 ) ISBN 7-81082 - 634-4... - : -. TP316-44 CIP ( 2005) 123583 : : : : 100084 : 010-62776969 : 100044 : 010-51686414
More informationC++ 程式設計
C C 料, 數, - 列 串 理 列 main 數串列 什 pointer) 數, 數, 數 數 省 不 不, 數 (1) 數, 不 數 * 料 * 數 int *int_ptr; char *ch_ptr; float *float_ptr; double *double_ptr; 數 (2) int i=3; int *ptr; ptr=&i; 1000 1012 ptr 數, 數 1004
More informationWindows RTEMS 1 Danilliu MMI TCP/IP QEMU i386 QEMU ARM POWERPC i386 IPC PC104 uc/os-ii uc/os MMI TCP/IP i386 PORT Linux ecos Linux ecos ecos eco
Windows RTEMS 1 Danilliu MMI TCP/IP 80486 QEMU i386 QEMU ARM POWERPC i386 IPC PC104 uc/os-ii uc/os MMI TCP/IP i386 PORT Linux ecos Linux ecos ecos ecos Email www.rtems.com RTEMS ecos RTEMS RTEMS Windows
More informationChapter12 Derived Classes
继 承 -- 派 生 类 复 习 1. 有 下 面 类 的 说 明, 有 错 误 的 语 句 是 : class X { A) const int a; B) X(); C) X(int val) {a=2 D) ~X(); 答 案 :C 不 正 确, 应 改 成 X(int val) : a(2) { 2. 下 列 静 态 数 据 成 员 的 特 性 中, 错 误 的 是 A) 说 明 静 态 数
More information科学计算的语言-FORTRAN95
科 学 计 算 的 语 言 -FORTRAN95 目 录 第 一 篇 闲 话 第 1 章 目 的 是 计 算 第 2 章 FORTRAN95 如 何 描 述 计 算 第 3 章 FORTRAN 的 编 译 系 统 第 二 篇 计 算 的 叙 述 第 4 章 FORTRAN95 语 言 的 形 貌 第 5 章 准 备 数 据 第 6 章 构 造 数 据 第 7 章 声 明 数 据 第 8 章 构 造
More information标题
吉 林 省 人 力 资 源 和 社 会 保 障 厅 文 件 吉 人 社 办 字 暡 2015 暢 57 号 关 于 做 好 2015 年 全 省 机 关 事 业 单 位 工 人 职 业 技 能 鉴 定 工 作 的 通 知 各 市 ( 州 ) 长 白 山 管 委 会 梅 河 口 市 公 主 岭 市 人 力 资 源 和 社 会 保 障 局, 省 直 各 部 门 ( 单 位 ), 中 直 驻 省 各 有
More information全台灣路邊攤美食清單.doc
(, (02 8780-0000 ( : (022702-4908 41 ( 2, 800~1000 1000~1500 ; : http://www.map.com.tw/ :,, 90 (022422-3007 159 (50 : ( 62 ( (022456-9281 ( 2 29 2-3 93 128 : ( / / : 93 ( ( 319 (022423-3620 50 1 (022425-0784
More informationuntitled
1 Outline 數 料 數 數 列 亂數 練 數 數 數 來 數 數 來 數 料 利 料 來 數 A-Z a-z _ () 不 數 0-9 數 不 數 SCHOOL School school 數 讀 school_name schoolname 易 不 C# my name 7_eleven B&Q new C# (1) public protected private params override
More informationMicrosoft Word - 2008年9月二级C真卷.doc
机 密 启 用 前 2008 年 9 月 全 国 计 算 机 等 级 考 试 二 级 笔 试 试 卷 C 语 言 程 序 设 计 24 注 意 事 项 一 考 生 应 严 格 遵 守 考 场 规 则, 得 到 监 考 人 员 指 令 后 方 可 作 答 二 考 生 拿 到 试 卷 后 应 首 先 将 自 己 的 姓 名 准 考 证 号 等 内 容 涂 写 在 答 题 卡 的 相 应 位 置 上 三
More informationb1²Ä¤@³¹¼Æ»P§¤¼Ð¨t
第 一 章 數 與 坐 標 系 大 學 聯 考 試 題 與 推 薦 甄 選 試 題 第 一 類 大 學 入 學 甄 試 試 題 評 量 1. 下 列 何 者 是 2 100 除 以 10 的 餘 數? (1) 0 (2) 2 (3) 4 (4) 6 (5) 8 88 年 2. 一 個 正 三 角 形 的 面 積 為 36, 今 截 去 三 個 角 ( 如 右 圖 ), 使 成 為 正 六 邊 形,
More information( ) A B C D ( ) A B C D A B C D A B C D A 8750 B C 6250 D 5000 A B C D A B C D
1 A B C D A B C D A B C D 1000 1200 900 A B C D ( ) A B C D ( ) A B C D A B C D A B C D 5000 6250 A 8750 B 11250 C 6250 D 5000 A B C D A B C D A B C D 1 200000 400 10 A 1000 B 1600 C 2000 D 2300 1 A B
More information51 C 51 isp 10 C PCB C C C C KEIL
http://wwwispdowncom 51 C " + + " 51 AT89S51 In-System-Programming ISP 10 io 244 CPLD ATMEL PIC CPLD/FPGA ARM9 ISP http://wwwispdowncom/showoneproductasp?productid=15 51 C C C C C ispdown http://wwwispdowncom
More informationzt
!!!!!!!!!!!!!!!!!!!! $ $ $ $ $ $ $ $ $ $ % $ % (!$ $ &% ) $ $ *) $ $ $ $ $ $ +) $ $ $ $ $ $,) $ $ $ $ $ $ -) $ $ $ $ $ $!) $ $ *) $ $ $ +) $ $ $,) $ $ $ -) $ $ $ () $ $ *) $ $ $ +),) -) &) $ $ *) +),)!
More information华恒家庭网关方案
LINUX V1.5 1 2 1 2 LINUX WINDOWS PC VC LINUX WINDOWS LINUX 90% GUI LINUX C 3 REDHAT 9 LINUX PC TFTP/NFS http://www.hhcn.com/chinese/embedlinux-res.html minicom NFS mount C HHARM9-EDU 1 LINUX HHARM9-EDU
More information新・解きながら学ぶJava
481! 41, 74!= 40, 270 " 4 % 23, 25 %% 121 %c 425 %d 121 %o 121 %x 121 & 199 && 48 ' 81, 425 ( ) 14, 17 ( ) 128 ( ) 183 * 23 */ 3, 390 ++ 79 ++ 80 += 93 + 22 + 23 + 279 + 14 + 124 + 7, 148, 16 -- 79 --
More informationuntitled
Introduction to Programming ( 數 ) Lecture 3 Spring 2005 March 4, 2005 Lecture 2 Outline 數 料 If if 狀 if 2 (Standard Output, stdout): 料. ((Standard Input, stdin): 料. 類 數 數 數 說 printf 見 數 puts 串 數 putchar
More informationuntitled
1 5 IBM Intel 1. IBM 第 1/175 页 第 2/175 页 第 3/175 页 80 第 4/175 页 2. IBM 第 5/175 页 3. (1) 第 6/175 页 第 7/175 页 第 8/175 页 = = 第 9/175 页 = = = = = 第 10/175 页 = = = = = = = = 3. (2) 第 11/175 页 第 12/175 页 第 13/175
More information列 出 所 有 的 非 負 整 數 解, 係 數 越 大 者 越 先 決 定, 故 先 決 定 z, 再 決 定 y, 最 後 決 定 x, 故 有 + 6 + = 8 ( 種 ) x 0 0 6 8 0 0 6 8 0 6 8 0 y 0 5 0 0 9 8 7 6 5 0 z 0 0 0 0 0
- 乘 法 原 理 基 礎 型. 從 甲 地 至 乙 地 有 5 條 路 可 走, 由 乙 地 至 丙 地 有 條 路 可 走, 由 丙 地 至 丁 地 有 條 路 可 走, 試 問 從 甲 地 經 乙 丙 兩 地 至 丁 地 的 走 法 有 幾 種? 答 60 解 由 乘 法 原 理 知, 有 5 = 60 ( 種 ). 書 店 的 書 架 上 有 種 不 同 的 英 文 書 和 5 種 不 同
More information! # % % & # # % #!& % &# % &# % % % # %& ( (!& (! & & % % #!! ) %&! *& % %! % %!! # % %!! %*!& % &# % &# ) ) ( % # # ) % ( (!& (! (!! # % % #!! # ( &!
!#!#!%!&!& #!#!#!#!#!#!! #!% # ( )! & & % & ) % ( %! # )& ) &!) &!% )& )! )!!% & ( (!&!&!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! )! % * % * ( & )!! % & # %! %! )! % * % * ( & )!! % & # %! %! # )! % * % *
More information## $%& %& ## () #) (( * (+++ () #) #) (+ (+ #) #) ( #, - #)). #))- # ( / / / 0 1 2 0 / $ # ( *. 3. 3 *..# 4 #$ 3 ( 5 ) ### 4 $ # 5, $ ## # 4 $# 5 ( %
# # $ %& $ %# ( $ # ( # $ ( $ $ ( ( % ( $ ( $ ( ( % ( % $ ( $ ( ( $ ( ( ( & ( ( ( $ ( ( % %# ( ( $ ( %# % ## $%& %& ## () #) (( * (+++ () #) #) (+ (+ #) #) ( #, - #)). #))- # ( / / / 0 1 2 0 / $ # ( *.
More information第六章 数据分析(排列组合、概率和数据描述)
考 纲. 排 列 组 合 第 六 章 数 据 分 析 ( 排 列 组 合 概 率 和 数 据 描 述 ) () 加 法 原 理 乘 法 原 理 () 排 列 与 排 列 数 () 组 合 与 组 合 数. 概 率 () 事 件 及 其 简 单 运 算 () 加 法 公 式 () 乘 法 公 式 () 古 典 概 型 () 贝 努 里 概 型. 数 据 描 述 一 排 列 组 合 ㈠ 知 识 要 点
More information<4D6963726F736F667420576F7264202D20C9CFBAA3B2C6BEADB4F3D1A732303133C4EAC9CFB5B3D1B5B0E0BDE1D2B5C0EDC2DBCCE2BFE2A3A8746F20D1A7D4B1A3A92E646F6378>
上 海 财 经 大 学 2013 年 第 2 期 师 生 预 备 党 员 积 极 分 子 培 训 班 结 业 理 论 考 试 题 一 单 选 题, 合 计 90 题 : 1 马 克 思 主 义 诞 生 的 最 根 本 的 历 史 条 件 是? () A 工 人 运 动 的 兴 起 B 资 本 主 义 的 迅 速 发 展 C 社 会 主 义 思 想 的 高 涨 D 吸 取 人 类 优 秀 文 化 成
More informationCC213
: (Ken-Yi Lee), E-mail: feis.tw@gmail.com 9 [P.11] : Dev C++ [P.12] : http://c.feis.tw [P.13] [P.14] [P.15] [P.17] [P.23] Dev C++ [P.24] [P.27] [P.34] C / C++ [P.35] 10 C / C++ C C++ C C++ C++ C ( ) C++
More informationIO
1 C/C++ C FILE* fscanf fgets fread fprintf fputs fwrite C++ ifstream ofstream >>
More informationC C C The Most Beautiful Language and Most Dangerous Language in the Programming World! C 2 C C C 4 C 40 30 10 Project 30 C Project 3 60 Project 40
C C trio@seu.edu.cn C C C C The Most Beautiful Language and Most Dangerous Language in the Programming World! C 2 C C C 4 C 40 30 10 Project 30 C Project 3 60 Project 40 Week3 C Week5 Week5 Memory & Pointer
More information目录
ALTERA_CPLD... 3 11SY_03091... 3 12SY_03091...4....5 21 5 22...8 23..10 24..12 25..13..17 3 1EPM7128SLC.......17 3 2EPM7032SLC.......18 33HT46R47......19..20 41..20 42. 43..26..27 5151DEMO I/O...27 52A/D89C51...28
More informationuntitled
1 1.1 1.2 1.3 1.4 1.5 ++ 1.6 ++ 2 BNF 3 4 5 6 7 8 1.2 9 1.2 IF ELSE 10 1.2 11 1.2 12 1.3 Ada, Modula-2 Simula Smalltalk-80 C++, Objected Pascal(Delphi), Java, C#, VB.NET C++: C OOPL Java: C++ OOPL C# C++
More information<443A5C4261636B75705CC4DAC8DD5CD2BBA1A2C6C0B9C0CEC4BCFE5C312EA1B6BDCCD3FDB2BFB0ECB9ABCCFCB9D8D3DAC8ABC3E6BFAAD5B9B8DFD6B0B8DFD7A8D4BAD0A3C8CBB2C5C5E0D1F8B9A4D7F7CBAEC6BDC6C0B9C0B5C4CDA8D6AAA1B7A3A8BDCCB8DFCCFC5B323030345D3136BAC5A3A92E646F6
教 学 与 督 导 特 刊 人 才 培 养 工 作 评 估 文 件 汇 编 目 录 一 评 估 文 件 1. 教 育 部 办 公 厅 关 于 全 面 开 展 高 职 高 专 院 校 人 才 培 养 工 作 水 平 评 估 的 通 知 ( 教 高 厅 [2004]16 号 ) 01 2. 教 育 部 关 于 印 发 < 高 等 职 业 院 校 人 才 培 养 工 作 评 估 方 案 > 的 通 知 (
More information因 味 V 取 性 又 鸟 U 且 最 大 罗 海 惜 梅 理 春 并 贵 K a t h l ee n S c h w e r d t n er M f l e z S e b a s t i a n C A Fe rs e T 民 伊 ' 国 漳 尤 地 视 峰 州 至 周 期 甚 主 第 应
国 ' 东 极 也 直 前 增 东 道 台 商 才 R od e ric h P t ak 略 论 时 期 国 与 东 南 亚 的 窝 贸 易 * 冯 立 军 已 劳 痢 内 容 提 要 国 与 东 南 亚 的 窝 贸 易 始 于 元 代 代 大 规 模 开 展 的 功 效 被 广 为 颂 扬 了 国 国 内 市 场 窝 的 匮 乏 窝 补 虚 损 代 上 流 社 会 群 体 趋 之 若 鹜 食 窝
More informationC PICC C++ C++ C C #include<pic.h> C static volatile unsigned char 0x01; static volatile unsigned char 0x02; static volatile unsigned cha
CYPOK CYPOK 1 UltraEdit Project-->Install Language Tool: Language Suite----->hi-tech picc Tool Name ---->PICC Compiler Executable ---->c:hi-picinpicc.exe ( Command-line Project-->New Project-->File Name--->myc
More informationPowerPoint Presentation
Visual Basic 2005 學 習 範 本 第 7 章 陣 列 的 活 用 7-1 陣 列 當 我 們 需 要 處 理 資 料 時, 都 使 用 變 數 來 存 放 資 料 因 為 一 個 變 數 只 能 代 表 一 個 資 料, 若 需 要 處 理 100 位 同 學 的 成 績 時, 便 要 使 用 100 個 不 同 的 變 數 名 稱, 這 不 但 會 增 加 變 數 名 稱 命 名
More information美鳳吃透透
鳳 中 奇 緣 台 灣 路 邊 攤 推 薦 美 食 ( 依 縣 市 區 域 ) 如 欲 查 詢 更 詳 盡 或 不 清 楚 的 資 料, 請 電 (02) 8780-0000 三 立 觀 眾 服 務 部 查 詢 ( 美 鳳 姐 開 ㄟ 店 : 鳳 廚 (02)2702-4908 台 北 市 復 興 南 路 二 段 41 號 ( 朝 代 飯 店 2 樓, 捷 運 木 柵 線 大 安 站 ) 價 格 :
More information上海市教育考试院关于印发新修订的
沪 教 考 院 社 考 2012 7 号 上 海 市 教 育 考 试 院 关 于 印 发 上 海 市 高 等 学 校 计 算 机 等 级 考 试 大 纲 (2012 年 修 订 ) 的 通 知 各 有 关 高 校 : 为 进 一 步 加 强 本 市 高 校 计 算 机 基 础 教 学 工 作, 推 进 学 校 更 加 科 学 合 理 地 设 置 计 算 机 基 础 课 程 及 安 排 教 学 内 容,
More information高 职 计 算 机 类 优 秀 教 材 书 目 * 序 号 书 号 (ISBN) 书 名 作 者 定 价 出 版 / 印 刷 日 期 ** 配 套 资 源 页 码 计 算 机 基 础 课 1 978-7-111-30658-0 计 算 机 应 用 基 础 刘 升 贵 29.00 2012 年 8 月
高 职 计 算 机 类 优 秀 教 材 书 目 * 序 号 书 号 (ISBN) 书 名 作 者 定 价 出 版 / 印 刷 日 期 ** 配 套 资 源 页 码 计 算 机 基 础 课 1 978-7-111-30658-0 计 算 机 应 用 基 础 刘 升 贵 29.00 2012 年 8 月 电 子 教 案 P1 2 978-7-111-27081-2 计 算 机 应 用 基 础 ( 第 2
More information数 学 高 分 的 展 望 一 管 理 类 联 考 分 析 第 一 篇 大 纲 解 析 篇 编 写 : 孙 华 明 1 综 合 能 力 考 试 时 间 :014 年 1 月 4 日 上 午 8:30~11:30 分 值 分 配 : 数 学 :75 分 逻 辑 :60 分 作 文 :65 分 ; 总
目 录 数 学 高 分 的 展 望... 1 第 一 篇 大 纲 解 析 篇... 1 一 管 理 类 联 考 分 析... 1 二 最 新 大 纲 解 析... 1 三 考 前 复 习 资 料 及 方 法... 第 二 篇 总 结 篇... 4 1 应 用 题 考 点 总 结 与 技 巧 归 纳... 4 代 数 模 块 题 型 归 纳 及 考 点 总 结... 9 3 数 列 模 块 题 型 归
More informationPs22Pdf
( ) 158,,,,,, ( CIP) /. :, 1996. 12 ISBN 7 302 02353 0... :. F275 CIP ( 96) 20860 : ( :, 100084) : : : 850 1168 1/ 32 : 13. 25 : 344 : 1996 12 1 1996 12 1 : ISBN 7 302 02353 0/ F 130 : 0001 5000 : 16.
More informatione 2 3 2
e 1 3 3.1 3.2 3.3 NextDate 3.4 3.5 3.6 3.7 3.8 3.9 3 1 e 2 3 2 e 3 3.1 3.1.1 3.1.2 3.1.3 3.1.4 Return 3 3 e 4 3.1.1 1 2 1 2 3 4 3 4 e 5 3.1.2 3 5 e 6 3.1.3 FAX MODEM 3 6 e 7 3.1.4 ANSI/IEEE829-1983 3 1
More informationPython a p p l e b e a r c Fruit Animal a p p l e b e a r c 2-2
Chapter 02 變數與運算式 2.1 2.1.1 2.1.2 2.1.3 2.1.4 2.2 2.2.1 2.2.2 2.2.3 type 2.2.4 2.3 2.3.1 print 2.3.2 input 2.4 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 + 2.4.6 Python Python 2.1 2.1.1 a p p l e b e a r c 65438790
More informationzt
" # $ % & ( ) " * " ) " % & + ( &, -. % & ( & # $ ( + - " " #$ %%&&& " ()( * %&+# %, %- % #&&# + % #&&# + %./01 ( 2 )&--+ 2 ) 2 -, 3#$4 "#$%& (#)"* # +,-- (#&. / " "#$%& (#)"* # 01&+%$"&2 (#&. / 33 33
More informationE. (A) (B) (C) (D). () () () (A) (B) (C) (D) (E). () () () (A) (B) (C) (D) (E). (A)(B)(C) (D) (E) (A) (B) (C) (D) (E) (A) (B)(C) (D) (E). (A) (B) (C)
. (A) (B) (C) (D) (A) (B) (C)(D)(E). (A) (B) (C) (D) (E) (A) (B) (C) (D). (A) (B) (C) (D) (E) (A) (B) (C) (D) (E). (A) (B) (C) (D) (E). (A) (B) (C) (D) (E). (A) (B) (C) (D) (E) (A) (B) (C) (D) (E). (A)
More informationuntitled
CHAPTER 02 2 CHAPTER 2-1 2-4 2-2 2-5 2-3 2-6 2-1 2-1-1 2-2 02 int A[3] = {10, 20, 30; A[0] 10 A[1] 20 A[2] 30 int *pa[3], A[3]; C 3 pa pa[0]pa[1]pa[2] 3 A A[0]A[1]A[2] 3 A A[0] A + i A[i] A + i &A[i]*(A
More informationuntitled
0.37kW 250kW D11.7 2009 SINAMICS G120 0.37kW 250kW SINAMICS G120 Answers for industry. SINAMICS G120 0.37kW 250kW SINAMICS G110 D 11.1 0.12 kw 3 kw CA01 MC CA01 MC CD : E20001-K20-C-V2-5D00 141-P90534-09020
More information上海市本科教学质量年度报告
上 海 市 本 科 教 学 质 量 年 度 报 告 数 据 内 涵 说 明 V2.0 版 上 海 市 教 委 高 教 处 上 海 喆 思 (2015.07.02) 目 录 一 基 本 统 计 挃 标 说 明... 4 二 挃 标 解 释... 4 1. 全 日 制 在 校 本 科 生 数 及 占 在 校 生 总 数 的 比 例 ( 学 年 )... 4 2. 当 年 本 科 招 生 与 业 总 数
More informationCHAPTER VC#
1. 2. 3. 4. CHAPTER 2-1 2-2 2-3 2-4 VC# 2-5 2-6 2-7 2-8 Visual C# 2008 2-1 Visual C# 0~100 (-32768~+32767) 2 4 VC# (Overflow) 2-1 2-2 2-1 2-1.1 2-1 1 10 10!(1 10) 2-3 Visual C# 2008 10! 32767 short( )
More information(京)新登字063号
教 育 部 职 业 教 育 与 成 人 教 育 司 推 荐 教 材 Java 程 序 设 计 教 程 ( 第 二 版 ) 沈 大 林 主 编 沈 昕 肖 柠 朴 曾 昊 等 编 著 内 容 简 介 Java 是 由 美 国 SUN 公 司 开 发 的 一 种 功 能 强 大 的, 具 有 简 单 面 向 对 象 分 布 式 可 移 植 等 性 能 的 多 线 程 动 态 计 算 机 编 程 语 言
More information