C/C++ - 结构体、共用体、枚举体
|
|
- 捷 康
- 4 years ago
- Views:
Transcription
1 C/C++
2 Table of contents
3
4 C C (struct) C 2
5 C C (struct) C 2
6 i // book.c: # include < stdio.h> # define MAX_ TITLE 41 # define MAX_ AUTHOR 31 struct book { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; }; int main ( void ) { struct book book ; printf (" Please enter the book title.\ n"); gets ( book. title ); printf (" Please enter the author.\n"); 3
7 ii } gets ( book. author ); printf (" Now enter the price.\n"); scanf ("%f", & book. price ); printf ("%s by %s: %.2 f\n", book. title, book. author, book. price ); return 0; 4
8 Please enter the book title. C primer plus Please enter the author. Stephan Prata Now enter the price. 90 C primer plus by Stephan Prata :
9 struct book { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; }; struct book 3 (member) 6
10
11 (structure declaration) struct book { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; }; 7
12 (structure declaration) struct book { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; }; char float 7
13 struct book struct book book ; book book C 8
14 9
15 typedef typedef typedef struct { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; } Book ; 10
16 typedef typedef typedef struct { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; } Book ; Book book ; 10
17 i // book1.c: # include < stdio.h> # define MAX_ TITLE 41 # define MAX_ AUTHOR 31 typedef struct { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; } Book ; int main ( void ) { Book book ; printf (" Please enter the book title.\ n"); gets ( book. title ); printf (" Please enter the author.\n"); 11
18 ii } gets ( book. author ); printf (" Now enter the price.\n"); scanf ("%f", & book. price ); printf ("%s by %s: %.2 f\n", book. title, book. author, book. price ); return 0; 12
19
20 typedef struct { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; } Book ; Book book ; Book book MAX_TITLE char MAX_AUTHOR char float book 13
21 Book int float Book Book book1, book2, * pbook ; 14
22 Book book ; struct { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; } book ; 15
23 struct { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; } book ; 16
24
25 Book library = { "C primer plus ", " Stephan Prata ", 80 }; 17
26
27 18
28 . 18
29 . book.price book price float book.price.title.author.price book 18
30
31 C99 Book price Book surprise = {. price = }; Book gift = {. price = 40.50,. author = " Dennis M. Ritchie ",. title = " The C programming language " }; 19
32
33
34 i // manybook.h: # include < stdio.h> # define MAX_ TITLE 41 # define MAX_ AUTHOR 31 # define MAX_ BOOK 100 typedef struct { char title [ MAX_ TITLE ]; char author [ MAX_ AUTHOR ]; float price ; } Book ; 20
35 i // manybook.c: # include " manybook.h" int main ( void ) { Book book [ MAX_BOOK ]; int count = 0; int i; printf (" Enter the book title.\n"); printf (" Press [ enter ] at the start of a line to stop.\n"); while ( count < MAX_ BOOK && gets ( book [ count ]. title )!= NULL && book [ count ]. title [0]!= \0 ) { printf (" Enter the author.\n"); gets ( book [ count ]. author ); printf (" Enter the price.\n"); 21
36 ii } scanf ("%f", & book [ count ++]. price ); while ( getchar ()!= \n ) continue ; if ( count < MAX_ BOOK ) printf (" Enter the next title.\n"); } if ( count > 0) { printf (" Here is the list of your book :\ n"); for ( i = 0; i < count ; i ++) printf ("%s by %s: %.2 f\n", book [i]. title, book [i]. author, book [i]. price ); } else { printf ("No book? Too bad!\n"); } return 0; 22
37 Enter the book title. Press [ enter ] at the start of a line to stop. C primer plus [ enter ] Enter the author. Stephan Prata [ enter ] Enter the price. 80[ enter ] Enter the next title. C programing language [ enter ] Enter the author. Dennis Ritchie [ enter ] Enter the price. 40[ enter ] Enter the next title. 23
38 Here is the list of your book : C primer plus by Stephan Prata : C programing language by Dennis Ritchie :
39
40 Book book [ MAX_BOOK ]; MAX_BOOK Book book Book 25
41
42 book [0]. price ; book [4]. title ; book [2]. title [4]; // 1 price // 5 title // 3 title // 5 26
43
44 John 27
45 i // friend.h # include < stdio.h> # define LEN 20 const char * msgs [5] = { " Thank your for the wonderful evening, ", " You certainly prove that a ", " is a special kind of guy. We must get together ", " over a delicous ", " and have a few laughs " }; typedef struct { char first [ LEN ]; char last [ LEN ]; } Name ; typedef struct { Name name ; 28
46 ii char favfood [ LEN ]; char job [ LEN ]; float income ; } Guy ; 29
47 i // friend.c # include " friend.h" int main ( void ) { Guy guy = { {" Ewen ", " Villard "}, " grilled salmon ", " personality coach ", }; printf (" Dear %s, \n\n", guy. name. first ); printf ("%s%s.\n", msgs [0], guy. name. first ); printf ("%s%s\n", msgs [1], guy. job ); printf ("%s\n", msgs [2]) ; printf ("%s%s%s", msgs [3], guy. favfood, msgs [4]) ; if ( guy. income > ) 30
48 ii } puts ("!!"); else if ( guy. income > ) puts ("!"); else puts ("."); printf ("\n %40 s%s\n", " ", " See you soon, "); printf (" %40 s%s\n", " ", " John "); return 0; 31
49 Dear Ewen, Thank your for the wonderful evening, Ewen. You certainly prove that a personality coach is a special kind of guy. We must get together over a delicous grilled salmonand have a few laughs!! See you soon, John 32
50 guy. name. first 33
51
52 1. 2. C 3. 34
53
54 Guy * him ; him Guy john Guy him = & john ; 35
55 Guy * him ; him Guy john Guy him = & john ; & 35
56 fellow Guy fellow [5]; fellow[0] him fellow[0] him = & fellow [0]; 36
57
58 him fellow[0] 1. -> him -> income is fellow [0]. income if him == & fellow [0] him him->income him 2.. fellow [0]. income == (* him ). income * 37
59 him fellow[0] fellow [0]. income == (* him ). income == him -> income 38
60
61
62
63 int, char, float, double 40
64 int, char, float, double 40
65 // student.h # include <stdio.h> # define LEN 50 typedef struct { char name [ LEN ]; int math, phys, chem ; } Student ; 41
66 # include " student.h" int total ( int math, int phys, int chem ); int main ( void ) { Student std = {" Zhang San ", 90, 85, 80}; printf (" Total score of %s is %d.\n", std.name, total ( std.math, std.phys, std. chem )); } int total ( int math, int phys, int chem ) { return math + phys + chem ; } 42
67
68 // student2.c # include " student.h" int total ( const Student *); int main ( void ) { Student std = {" Zhang San ", 90, 85, 80}; printf (" Total score of %s is %d.\n", std.name, total (& std )); } int total ( const Student * std ) { return std -> math + std -> phys + std -> chem ; } 43
69
70 // student3.c # include " student.h" int total ( const Student ); int main ( void ) { Student std = {" Zhang San ", 90, 85, 80}; printf (" Total score of %s is %d.\n", std.name, total ( std )); } int total ( const Student std ) { return std. math + std. phys + std. chem ; } 44
71
72 C n_data o_data o_data = n_data ; o_data n_data 45
73 Name name1 = {" Ruthie ", " George "}; Name name2 = name1 ; 46
74 C 47
75 i // names.h # include <stdio.h> # include <string.h> typedef struct { char first [20]; char last [20]; int letters ; } Name ; void getinfo ( Name *); void makeinfo ( Name *); void showinfo ( const Name *); 48
76 i // info.c # include " names.h" void getinfo ( Name * pname ) { puts (" Enter your first name."); gets ( pname -> first ); puts (" Enter your last name."); gets ( pname -> last ); } void makeinfo ( Name * pname ) { pname -> letters = ( int ) strlen ( pname -> first ) + ( int ) strlen ( pname -> last ); } void showinfo ( const Name * pname ) { 49
77 ii } printf ("%s %s, your name contains %d letters.\n", pname -> first, pname ->last, pname -> letters ); 50
78 i // main.c # include " names.h" int main ( void ) { Name person ; getinfo (& person ); makeinfo (& person ); showinfo (& person ); return 0; } 51
79 Enter your first name. Stepha Enter your last name. Prata Stephan Prata, your name contains 12 letters. 52
80 53
81 i // names.h # include <stdio.h> # include <string.h> typedef struct { char first [20]; char last [20]; int letters ; } Name ; Name getinfo ( void ); Name makeinfo ( Name ); void showinfo ( Name ); 54
82 i // info.c # include " names.h" Name getinfo ( void ) { Name name ; puts (" Enter your first name."); gets ( name. first ); puts (" Enter your last name."); gets ( name. last ); return name ; } Name makeinfo ( Name name ) { name. letters = ( int ) strlen ( name. first ) + ( int ) strlen ( name. last ); return name ; 55
83 ii } void showinfo ( Name name ) { printf ("%s %s, your name contains %d letters.\n", name. first, name.last, name. letters ); } 56
84 i // main.c # include " names.h" int main ( void ) { Name person ; person = getinfo (); person = makeinfo ( person ); showinfo ( person ); return 0; } 57
85
86 58
87 1. C 2. const 59
88 C 2. 60
89 61
90 i # include <stdio.h> # include <math.h> typedef struct { double val [3]; } Vec ; Vec add ( Vec a, Vec b) { Vec c; for ( int i = 0; i < 3; i ++) c. val [i] = a. val [i] + b. val [i]; return c; } Vec sub ( Vec a, Vec b) { Vec c; for ( int i = 0; i < 3; i ++) 62
91 ii c. val [i] = a. val [i] - b. val [i]; return c; } double dot ( Vec a, Vec b) { return a. val [0]* b. val [0] + a. val [1]* b. val [1] + a. val [2]* b. val [2]; } double norm ( Vec a) { return sqrt ( dot (a, a)); } void show ( Vec a) { 63
92 iii } printf (" <%.2f, %.2f, %.2f >\n", a. val [0], a. val [1], a. val [2]) ; 64
93 # include " vector.h" int main ( void ) { Vec a = {1.0, 1.0, 1.0}; Vec b = {1.0, 2.0, 3.0}; Vec c; c = add (a, b); printf ("a + b = "); show (c); c = sub (a, b); printf ("a - b = "); show (c); printf ("(a, b) = %.2 f\n", dot (a, b)); printf (" a = %.2 f\n", norm (a)); return 0; } 65
94 const 66
95
96 typedef struct { char first [20]; char last [20]; } Name ; typedef struct { char * first ; char * last ; } pname ; 67
97 typedef struct { char first [20]; char last [20]; } Name ; typedef struct { char * first ; char * last ; } pname ; 67
98 Name name1 = {" Stephan ", " Prata "}; pname name2 = {" Dennis ", " Ritche "}; printf ("%s %s", name1. first, name2. last ); 68
99 Name name1 40 pname name pname 69
100 Name boy ; pname girl ; puts (" Enter the last name of the boy "); scanf ("%s", boy. last ); puts (" Enter the last name of the girl "); scanf ("%s", girl. last ); // 70
101 boy boy last girl scanf() girl.last 71
102 malloc() 72
103 malloc()
104 malloc() malloc() malloc() 73
105 malloc() i // names.h # include <stdio.h> # include <stdlib.h> # include <string.h> typedef struct { char * first ; char * last ; int letters ; } Name ; void getinfo ( Name *); void makeinfo ( Name *); void showinfo ( const Name *); void cleanup ( Name *); 74
106 malloc() i // info.c # include " names.h" void getinfo ( Name * pname ) { char temp [81]; puts (" Enter your first name."); gets ( temp ); pname -> first = ( char *) malloc ( strlen ( temp ) +1) ; strcpy ( pname -> first, temp ); puts (" Enter your last name."); gets ( temp ); pname -> last = ( char *) malloc ( strlen ( temp ) +1) ; strcpy ( pname ->last, temp ); } void makeinfo ( Name * pname ) 75
107 malloc() ii { } pname -> letters = ( int ) strlen ( pname -> first ) + ( int ) strlen ( pname -> last ); void showinfo ( const Name * pname ) { printf ("%s %s, your name contains %d letters.\n", pname -> first, pname ->last, pname -> letters ); } void cleanup ( Name * pname ) { free ( pname -> first ); free ( pname -> last ); } 76
108 malloc() // main.c # include " names.h" int main ( void ) { Name person ; getinfo (& person ); makeinfo (& person ); showinfo (& person ); cleanup (& person ); return 0; } 77
109 malloc() malloc() malloc() free() cleanup() 78
110
111 (union) 79
112 typedef union { int digit ; double bigfl ; char letter ; } Hold ; int double char 80
113 3 hold Hold fit ; Hold save [10]; Hold * pu; fit double 8 save 10 8 hold 81
114 C99 Hold vala ; vala. letter = R ; Hold valb = vala ; Hold valc = {88}; Hold vald = {. bigfl = }; 82
115 Hold fit ; fit. digit = 23; // 23 fit 2 fit. bigfl = 2.0; // fit. letter = h ; // 2.0 h 1 83
116 -> Hold * pu; Hold fit ; pu = & fit ; x = pu -> digit ; // x = fit.digit fit. letter = A ; flnum = 3.2 * fit. bigfl ; // 84
117 typedef struct { char socsecurity [ 20];... } Owner ; typedef struct { char name [40]; char headquarters [ 40];... } LeaseCompany ; 85
118 typedef union { Owner owncar ; LeaseCompany leasecar ; } Info ; typedef struct { char make [15]; int status ; // 0 = 1 = Info info ;... } CarInfo ; 86
119 honda CarInfo honda.status 0 ( ) honda.info.owncar.socsecurity; honda.status 1 ( ) honda.info.leasecar.name. 87
120
121 (enumerated type) enum enum int int 88
122 typedef enum { red, orange, yellow, green, blue } Spectrum ; Spectrum color ; Spectrum Spectrum color Spectrum 89
123 int c; color = blue ; if ( color == yellow )... for ( color = red ; color <= blue ; color ++)... Spectrum
124 printf (" red = %d, orange = %d\n", red, orange ); red = 0, orange = 1 red
125 0, 1, 2 nina 3 enum kids { nippy, slats, skippy, nina, liz }; 92
126 typedef enum { low = 100, medium = 500, high = 2000 } Level ; typedef enum { cat, lynx = 10, puma, tiger } Animal ; cat 0 lynx puma tiger
127 enum red blue
128 enum i # include <stdio.h> # include <string.h> # include < stdbool.h> typedef enum { red, orange, yellow, green, blue, violet } Spectrum ; const char * colors [] = { " red ", " orange ", " yellow ", " green ", " blue ", " violet " }; # define LEN 30 int main ( void ) { char choice [ LEN ]; Spectrum color ; bool color_ is_ found = false ; puts (" Enter a color ( empty line to quit ):"); while ( gets ( choice )!= NULL && choice [0]!= \0 ) { 95
129 enum ii for ( color = red ; color <= violet ; color ++) { if ( strcmp ( choice, colors [ color ]) == 0) { color_ is_ found = true ; break ; } } if ( color_is_found ) switch ( color ) { case red : puts (" Roes are red."); break ; case orange : puts (" Poppies are orange."); break ; case yellow : puts (" Sunflowers are yellow."); break ; case green : puts (" Grass is green."); break ; case blue : puts (" Bluebells are blue."); break ; case violet : puts (" Violets are violet."); break ; } 96
130 enum iii } else printf ("I don t know about the color %s.\n", choice ); color_ is_ found = false ; puts (" Next color, please ( empty line to quit ): "); } puts (" Goodbye!"); return 0; 97
131 enum i Enter a color ( empty line to quit ): orange Poppies are orange. Next color, please ( empty line to quit ): blue Bluebells are blue. Next color, please ( empty line to quit ): red Roes are red. Next color, please ( empty line to quit ): sdf I don t know about the color sdf. Next color, please ( empty line to quit ): Goodbye! 98
132 typedef
133 typedef typedef #define #define typedef typedef typedef #define 99
134 typedef typedef unsigned char BYTE ; BYTE x, y [10], * z; unsigned char BYTE BYTE typedef 100
135 typedef typedef char * STRING ; STRING char STRING name, sign ; char * name, * sign ; 101
136 typedef # define STRING char *; STRING name, sign ; char * name, sign ; 102
137 typedef typedef typedef struct complex { float real ; float imag ; } COMPLEX ; COMPLEX struct complex typedef 103
138 typedef typedef typedef struct { double x; double y; } vector ; 104
139 typedef vector v1 = {3.0, 6. 0}; vector v2; v2 = v1; struct { double x; double y; } v1 = {3.0, 6. 0}; struct { double x; double y; } v2; v2 = v1; 105
140 typedef typedef typedef typedef char (* FRPTC ()) [5]; FRPTC 5 char 106
141 typedef typedef 107
142
143 int board [8][8]; //int int ** ptr ; // int int * risk [10]; // 10 int int (* rusk ) [10]; // 10 int int * oof [3][4]; // 3x4 int int (* uuf ) [3][4]; // 3X4 int int (* uof [3]) [4]; // 3 // 4 int 108
144 char * fump (); // char char (* frump ) (); // char char (* flump [3]) (); // 3 char 109
145 typedef int arr5 [5] typedef arr5 * p_ arr5 ; typedef p_ arr5 arrp10 [ 10]; arr5 togs ; //togs 5 int p_arr5 p2; //p2 5 int arrp10 ap; //ap 10 // 5 int 110
146
147
148 int * int * f ( int a, int b); 111
149 i # include <stdio.h> # include <stdlib.h> int * f( int a, int b); int main ( void ) { int * q = NULL ; printf (" Memory address of q = %p\n", q); q = f(1, 2); printf (" Memory address of q = %p\n", q); printf ("*q = %d \n", *q); return 0; } int * f( int a, int b) { int * p = ( int *) malloc ( sizeof ( int )); 112
150 ii } printf (" Memory address of p = %p\n", p); *p = a + b; printf ("*p = %d \n", *p); return p; 113
151 Memory address of q = ( nil ) Memory address of p = 0 x5627e8f93670 *p = 3 Memory address of q = 0 x5627e8f93670 *q = 3 114
152
153 int (* f) ( int a, int b); * 115
154 i int 116
155 i # include <stdio.h> # include <stdlib.h> int max ( int a, int b); int min ( int a, int b); int (*f) (int, int ); int main ( void ) { f = max ; printf (" The max value is %d \n", (*f)(1, 2)); f = min ; printf (" The min value is %d \n", (*f)(1, 2)); return 0; } int max ( int a, int b) 117
156 ii { return (a > b? a : b); } int min ( int a, int b) { return (a < b? a : b); } 118
157 The max value is 2 The min value is 1 119
158 i double 120
159 i // fun_ptr1.h # include <stdio.h> # include <stdlib.h> # include <math.h> void Add ( double a, double b) { printf (" %8.3 f + %8.3 f = %8.3 f\n", a, b, a + b) ; } void Sub ( double a, double b) { printf (" %8.3 f - %8.3 f = %8.3 f\n", a, b, a - b) ; } 121
160 ii void Mul ( double a, double b) { printf (" %8.3 f * %8.3 f = %8.3 f\n", a, b, a * b) ; } void Div ( double a, double b) { if ( fabs (b) < 1.e -12) { printf (" Denominator is nearly zero!\n"); exit ( EXIT_FAILURE ); } printf (" %8.3 f / %8.3 f = %8.3 f\n", a, b, a / b) ; } 122
161 i // fun_ptr1.c # include " fun_ptr1.h" int main () { void (* mathop []) ( double, double ) = {Add, Sub, Mul, Div }; int choice ; double a = 15.0, b = 3. 0; printf (" Enter choice : 0 for add ; 1 for substract \n"); printf (" 2 for multiply ; 3 for division \n"); scanf ("%d", & choice ); if ( choice > 3) return 0; 123
162 ii } (* mathop [ choice ])(a, b); return 0; 124
163 i double 125
164 i // fun_ptr2.h # include <stdio.h> # include <stdlib.h> # include <math.h> double Add ( double a, double b) { return a + b; } double Sub ( double a, double b) { return a - b; } double Mul ( double a, double b) { 126
165 ii return a * b; } double Div ( double a, double b) { if ( abs (b) < 1.e -12) { printf (" Denominator is nearly zero!\n"); exit ( EXIT_FAILURE ); } return a / b; } double domath ( double a, double b, double (* mathop )( double, double ) ) { return (* mathop )(a, b); } 127
166 iii 128
167 i // fun_ptr2.c # include " fun_ptr2.h" int main ( void ) { printf (" Add gives : %8.3 f\n", domath (10., 2., Add )); printf (" Sub gives : %8.3 f\n", domath (10., 2., Sub )); printf (" Mul gives : %8.3 f\n", domath (10., 2., Mul )); printf (" Div gives : %8.3 f\n", domath (10., 0., Div )); return 0; } 129
C
C 12 2017 5 17 1. 2. 3. 4. 5. 6. 7. 2/156 C 8. 9. 10. typedef 11. 12. 3/156 C 1. 5/156 C I 1 // book.c: 2 #include 3 #define MAXTITL 41 4 #define MAXAUTL 31 5 struct book 6 { 7 char title[maxtitl];
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言語入門編
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++ - 函数
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言語入門編『索引』
!... 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 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 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++ 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. 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 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 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 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 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/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 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 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 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 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 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 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_汪_文前新ok[3.1].doc
普 通 高 校 本 科 计 算 机 专 业 特 色 教 材 精 选 四 川 大 学 计 算 机 学 院 国 家 示 范 性 软 件 学 院 精 品 课 程 基 金 青 年 基 金 资 助 项 目 C 语 言 程 序 设 计 (C99 版 ) 陈 良 银 游 洪 跃 李 旭 伟 主 编 李 志 蜀 唐 宁 九 李 涛 主 审 清 华 大 学 出 版 社 北 京 i 内 容 简 介 本 教 材 面 向
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 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 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 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 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++ - 数组与指针
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 2017 4 1 1. 2. while 3. 4. 5. for 6. 2/161 C 7. 8. (do while) 9. 10. (nested loop) 11. 12. 3/161 C 1. I 1 // summing.c: 2 #include 3 int main(void) 4 { 5 long num; 6 long sum = 0L; 7 int status;
More informationMicrosoft Word - 把时间当作朋友(2011第3版)3.0.b.06.doc
2 5 8 11 0 13 1. 13 2. 15 3. 18 1 23 1. 23 2. 26 3. 28 2 36 1. 36 2. 39 3. 42 4. 44 5. 49 6. 51 3 57 1. 57 2. 60 3. 64 4. 66 5. 70 6. 75 7. 83 8. 85 9. 88 10. 98 11. 103 12. 108 13. 112 4 115 1. 115 2.
More informationFY.DOC
高 职 高 专 21 世 纪 规 划 教 材 C++ 程 序 设 计 邓 振 杰 主 编 贾 振 华 孟 庆 敏 副 主 编 人 民 邮 电 出 版 社 内 容 提 要 本 书 系 统 地 介 绍 C++ 语 言 的 基 本 概 念 基 本 语 法 和 编 程 方 法, 深 入 浅 出 地 讲 述 C++ 语 言 面 向 对 象 的 重 要 特 征 : 类 和 对 象 抽 象 封 装 继 承 等 主
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 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新・解きながら学ぶ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 informationMicrosoft Word - 97.01.30軟體設計第二部份範例試題_C++_ _1_.doc
電 腦 軟 體 設 計 乙 級 技 術 士 技 能 檢 定 術 科 測 試 範 例 試 題 (C++) 試 題 編 號 :11900-920201-4 審 定 日 期 : 94 年 7 月 1 日 修 訂 日 期 : 96 年 2 月 1 日 97 年 1 月 30 日 ( 第 二 部 份 ) 電 腦 軟 體 設 計 乙 級 技 術 士 技 能 檢 定 術 科 測 試 應 檢 參 考 資 料 壹 試
More information2013 C 1 # include <stdio.h> 2 int main ( void ) 3 { 4 int cases, a, b, i; 5 scanf ("%d", & cases ); 6 for (i = 0;i < cases ;i ++) 7 { 8 scanf ("%d %d
2013 18 ( ) 1. C pa.c, pb.c, 2. C++ pa.cpp, pb.cpp, Compilation Error cin scanf Time Limit Exceeded 1: A 5 B 5 C 5 D 5 E 5 F 5 1 2013 C 1 # include 2 int main ( void ) 3 { 4 int cases, a, b,
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 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 information1 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 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 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 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 informationMicrosoft Word - CPE考生使用手冊160524.docx
大 學 程 式 能 力 檢 定 (CPE) 考 生 使 用 手 冊 2016 年 5 月 24 日 這 份 手 冊 提 供 給 參 加 CPE 檢 定 考 試 的 考 生 內 容 包 含 考 試 環 境 的 使 用, 以 及 解 題 時 所 使 用 I/O 的 基 本 知 識 1. 如 欲 報 名 參 加 CPE 考 試, 請 先 於 CPE 網 站 完 成 帳 號 註 冊, 然 後 再 報 名 該
More informationextend
(object oriented) Encapsulation Inheritance Polymorphism Dynamic Binding (base class) (derived class) 1 class Base { int I; void X(); void Y(); class Derived: public Base { private: int j; void z(); Derived
More informationMicrosoft PowerPoint - ds-1.ppt [兼容模式]
http://jwc..edu.cn/jxgl/ HomePage/Default.asp 2 说 明 总 学 时 : 72( 学 时 )= 56( 课 时 )+ 16( 实 验 ) 行 课 时 间 : 第 1 ~14 周 周 学 时 : 平 均 每 周 4 学 时 上 机 安 排 待 定 考 试 时 间 : 课 程 束 第 8 11 12 章 的 内 容 为 自 学 内 容 ; 目 录 中 标 有
More informationC 1 # include <stdio.h> 2 int main ( void ) { 4 int cases, i; 5 long long a, b; 6 scanf ("%d", & cases ); 7 for (i = 0;i < cases ;i ++) 8 { 9
201 201 21 ( ) 1. C pa.c, pb.c, 2. C++ pa.cpp, pb.cpp Compilation Error long long cin scanf Time Limit Exceeded 1: A 1 B 1 C 5 D RPG 10 E 10 F 1 G II 1 1 201 201 C 1 # include 2 int main ( void
More information2013 C 1 #include <stdio.h> 2 int main(void) 3 { 4 int cases, i; 5 long long a, b; 6 scanf("%d", &cases); 7 for (i = 0; i < cases; i++) 8 { 9 scanf("%
2013 ( 28 ) ( ) 1. C pa.c, pb.c, 2. C++ pa.cpp, pb.cpp Compilation Error long long cin scanf Time Limit Exceeded 1: A 10 B 1 C 1 D 5 E 5 F 1 G II 5 H 30 1 2013 C 1 #include 2 int main(void) 3
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 informationLorem ipsum dolor sit amet, consectetuer adipiscing elit
English for Study in Australia 留 学 澳 洲 英 语 讲 座 Lesson 3: Make yourself at home 第 三 课 : 宾 至 如 归 L1 Male: 各 位 朋 友 好, 欢 迎 您 收 听 留 学 澳 洲 英 语 讲 座 节 目, 我 是 澳 大 利 亚 澳 洲 广 播 电 台 的 节 目 主 持 人 陈 昊 L1 Female: 各 位
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 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 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 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 informationMicrosoft PowerPoint - C_Structure.ppt
結構與其他資料型態 Janet Huang 5-1 結構的宣告 struct 結構名稱 struct 結構名稱變數 1, 變數 2,, 變數 m; struct 結構名稱 變數 1, 變數 2,, 變數 m; student; student; 5-2 1 結構變數初值的設定 struct 結構名稱 struct 結構名稱變數 = 初值 1, 初值 2,, 初值 n student="janet","1350901",100,95
More information3. 給 定 一 整 數 陣 列 a[0] a[1] a[99] 且 a[k]=3k+1, 以 value=100 呼 叫 以 下 兩 函 式, 假 設 函 式 f1 及 f2 之 while 迴 圈 主 體 分 別 執 行 n1 與 n2 次 (i.e, 計 算 if 敘 述 執 行 次 數, 不
1. 右 側 程 式 正 確 的 輸 出 應 該 如 下 : * *** ***** ******* ********* 在 不 修 改 右 側 程 式 之 第 4 行 及 第 7 行 程 式 碼 的 前 提 下, 最 少 需 修 改 幾 行 程 式 碼 以 得 到 正 確 輸 出? (A) 1 (B) 2 (C) 3 (D) 4 1 int k = 4; 2 int m = 1; 3 for (int
More informationebook39-5
5 3 last-in-first-out, LIFO 3-1 L i n e a r L i s t 3-8 C h a i n 3 3. 8. 3 C + + 5.1 [ ] s t a c k t o p b o t t o m 5-1a 5-1a E D 5-1b 5-1b E E 5-1a 5-1b 5-1c E t o p D t o p D C C B B B t o p A b o
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 informationMicrosoft Word - 01.DOC
第 1 章 JavaScript 简 介 JavaScript 是 NetScape 公 司 为 Navigator 浏 览 器 开 发 的, 是 写 在 HTML 文 件 中 的 一 种 脚 本 语 言, 能 实 现 网 页 内 容 的 交 互 显 示 当 用 户 在 客 户 端 显 示 该 网 页 时, 浏 览 器 就 会 执 行 JavaScript 程 序, 用 户 通 过 交 互 式 的
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 informationCHAPTER 1
CHAPTER 1 1-1 System Development Life Cycle; SDLC SDLC Waterfall Model Shelly 1995 1. Preliminary Investigation 2. System Analysis 3. System Design 4. System Development 5. System Implementation and Evaluation
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 informationWindows XP
Windows XP What is Windows XP Windows is an Operating System An Operating System is the program that controls the hardware of your computer, and gives you an interface that allows you and other programs
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蔡 氏 族 譜 序 2
1 蔡 氏 族 譜 Highlights with characters are Uncle Mike s corrections. Missing or corrected characters are found on pages 9, 19, 28, 34, 44. 蔡 氏 族 譜 序 2 3 福 建 仙 遊 赤 湖 蔡 氏 宗 譜 序 蔡 氏 之 先 出 自 姬 姓 周 文 王 第 五 子
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立 志 于 打 造 最 贴 近 考 生 实 际 的 辅 导 书 计 算 机 考 研 之 数 据 结 构 高 分 笔 记 率 辉 编 著 周 伟 张 浩 审 核 讨 论 群 :15945769
立 志 于 打 造 最 贴 近 考 生 实 际 的 辅 导 书 计 算 机 考 研 之 数 据 结 构 高 分 笔 记 率 辉 编 著 周 伟 张 浩 审 核 讨 论 群 :15945769 前 言 在 计 算 机 统 考 的 四 门 专 业 课 中, 最 难 拿 高 分 的 就 是 数 据 结 构 但 是 这 门 课 本 身 的 难 度 并 不 是 考 生 最 大 的 障 碍, 真 正 的 障 碍
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 information扉页
目 录 关 于 2015 年 广 东 省 人 力 资 源 市 场 工 资 指 导 价 位 及 行 业 人 工 成 本 信 息 的 说 明 1 第 一 部 分 工 资 指 导 价 位 4 一 分 工 资 指 导 价 位 4 ( 一 ) 分 细 类 工 资 指 导 价 位 4 1 单 位 负 责 人 4 2 专 业 技 术 人 员 4 3 办 事 人 员 12 4 商 业 服 务 业 人 员 14 5
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 information概述
OPC Version 1.6 build 0910 KOSRDK Knight OPC Server Rapid Development Toolkits Knight Workgroup, eehoo Technology 2002-9 OPC 1...4 2 API...5 2.1...5 2.2...5 2.2.1 KOS_Init...5 2.2.2 KOS_InitB...5 2.2.3
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 information四川省普通高等学校
四 川 省 普 通 高 等 学 校 计 算 机 应 用 知 识 和 能 力 等 级 考 试 考 试 大 纲 (2013 年 试 行 版 ) 四 川 省 教 育 厅 计 算 机 等 级 考 试 中 心 2013 年 1 月 目 录 一 级 考 试 大 纲 1 二 级 考 试 大 纲 6 程 序 设 计 公 共 基 础 知 识 6 BASIC 语 言 程 序 设 计 (Visual Basic) 9
More information02
Thinking in C++: Volume One: Introduction to Standard C++, Second Edition & Volume Two: Practical Programming C++ C C++ C++ 3 3 C C class C++ C++ C++ C++ string vector 2.1 interpreter compiler 2.1.1 BASIC
More information<D0A1B0E02E707562>
小 一 班 专 题 活 动 生 日 蛋 糕 生 日 蛋 糕 是 孩 子 们 最 喜 欢 的 食 物, 他 们 期 盼 着 每 次 生 日 的 到 来 吹 蜡 烛 许 心 愿 吃 蛋 糕, 经 常 出 现 在 孩 子 们 的 区 域 游 戏 中, 因 此, 我 们 确 定 了 本 次 专 题 研 习 的 方 向 生 日 蛋 糕 结 合 专 题 探 究 的 需 要,11 月 10 日 我 们 同 孩 子
More information1 Framework.NET Framework Microsoft Windows.NET Framework.NET Framework NOTE.NET NET Framework.NET Framework 2.0 ( 3 ).NET Framework 2.0.NET F
1 Framework.NET Framework Microsoft Windows.NET Framework.NET Framework NOTE.NET 2.0 2.0.NET Framework.NET Framework 2.0 ( 3).NET Framework 2.0.NET Framework ( System ) o o o o o o Boxing UnBoxing() o
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 informationMicrosoft Word doc
中 考 英 语 科 考 试 标 准 及 试 卷 结 构 技 术 指 标 构 想 1 王 后 雄 童 祥 林 ( 华 中 师 范 大 学 考 试 研 究 院, 武 汉,430079, 湖 北 ) 提 要 : 本 文 从 结 构 模 式 内 容 要 素 能 力 要 素 题 型 要 素 难 度 要 素 分 数 要 素 时 限 要 素 等 方 面 细 致 分 析 了 中 考 英 语 科 试 卷 结 构 的
More informationC语言的应用.PDF
AVR C 9 1 AVR C IAR C, *.HEX, C,,! C, > 9.1 AVR C MCU,, AVR?! IAR AVR / IAR 32 ALU 1KBytes - 8MBytes (SPM ) 16 MBytes C C *var1, *var2; *var1++ = *--var2; AVR C 9 2 LD R16,-X ST Z+,R16 Auto (local
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 informationC, Win-TC Turbo C,, C, C,,,, C C, : Win-TC C, 23,,, 15,, C Turbo C Win-TC Turbo C,,,, 2005 1 W in -TC 1 Win-TC 1 1. Win-TC 1 2. Win-TC 1 3. Win-TC 1 2 Win-TC 3 1. 3 2. 3 3. 4 4. 4 5. 4 6. 4 7. 5 8. 5 9.
More informationebook8-30
3 0 C C C C C C++ C + + C++ GNU C/C++ GNU egcs UNIX shell s h e l l g a w k P e r l U N I X I / O UNIX shell awk P e r l U N I X C C C C C C U N I X 30.1 C C U N I X 70 C C U N I X U N I X U N I X C Dennis
More informationuntitled
1 7 7.1 7.2 7.3 7.4 7.5 2 7.1 VFT virtual 7.1 3 1 1. 2. public protected public 3. VFT 4. this const volatile 4 2 5. ( ) ( ) 7.1 6. no-static virtual 7.2 7. inline 7.3 5 3 8. this this 9. ( ) ( ) delete
More information例 度 讀 讀 不 不 來 念 來 了 讀 不 不 讀 不 讀行 利 了 說 更 了 讀
讀 爛 來 都 力 讀 不 讀 了 讀 來 讀 了 更 不 都 六年 類 更 錄 不 都 便 路 不 不 了 讀 來不 讀 讀 刺 數 不 刺 讀 索 料 易 力 練 讀 易 料 了 讀 力 讀便不 讀 例 度 讀 讀 不 不 來 念 來 了 讀 不 不 讀 不 讀行 利 了 說 更 了 讀 年 來 句 易 說 說 易 說 讀 識 識 力 句 老 錄 朗讀 讀 了 易 臨 說讀 力 識 樂 參 練
More informationGenerated by Unregistered Batch DOC TO PDF Converter , please register! 浙江大学 C 程序设计及实验 试题卷 学年春季学期考试时间 : 2003 年 6 月 20 日上午 8:3
浙江大学 C 程序设计及实验 试题卷 2002-2003 学年春季学期考试时间 : 2003 年 6 月 20 日上午 8:30-10:30 注意 : 答题内容必须写在答题卷上, 写在本试题卷上无效 一. 单项选择题 ( 每题 1 分, 共 10 分 ) 1. 下列运算符中, 优先级最低的是 A.
More informationWWW PHP Comments Literals Identifiers Keywords Variables Constants Data Types Operators & Expressions 2
WWW PHP 2003 1 Comments Literals Identifiers Keywords Variables Constants Data Types Operators & Expressions 2 Comments PHP Shell Style: # C++ Style: // C Style: /* */ $value = $p * exp($r * $t); # $value
More informationLOVE IS OVER LOVE LOVE LOVE LOVE IS EVERYTHING LOVE LOVE LOVE LOVER'S QUEEN LYDIA MAYBE TOMORROW MEN'S TALK MY DEAR MY FRIEND MY OH MY MY SUMMER DREAM
曲名 1234 20.30.40 5678 GOING 929 9907 A BTTER DAY ANDY BABY I'M YOUR MAN BACK HOME BAD BOY BEAUTIFUL GIRL BABY BABY BACK HOME BEAUTIFUL DAY BECAUSE OF YOU BETTER MAN CAN'T STOP LOVING YOU CALL ME CAN YOU
More informationFun Time (1) What happens in memory? 1 i n t i ; 2 s h o r t j ; 3 double k ; 4 char c = a ; 5 i = 3; j = 2; 6 k = i j ; H.-T. Lin (NTU CSIE) Referenc
References (Section 5.2) Hsuan-Tien Lin Deptartment of CSIE, NTU OOP Class, March 15-16, 2010 H.-T. Lin (NTU CSIE) References OOP 03/15-16/2010 0 / 22 Fun Time (1) What happens in memory? 1 i n t i ; 2
More information余德浩诗词
余德浩诗词 共 722 首 其中夕照新篇 436 首 2016 年 35 首 2015 年 81 首 2014 年 59 首 2013 年 64 首 2012 年 63 首 2011 年 79 首 2010 年 55 首 科苑情怀 1978-2009 年 39 首 青春足迹 1964-1977 年 241 首 自由体长诗 6 首 夕照新篇 2010-2016 年 读网络奇文随感三首 2016 年 5
More informationChapter 1 What is Programing Paradigm 1
An Introduction to Programing Paradigm Chase Zhang May 8, 2013 Chapter 1 What is Programing Paradigm 1 CHAPTER 1. WHAT IS PROGRAMING PARADIGM 2 Definition from Wikipedia 1. Object-oriented programming/
More informationMicrosoft Word - 把时间当作朋友(2011第3版)3.0.b.07.doc
2 5 8 11 0 1. 13 2. 15 3. 18 1 1. 22 2. 25 3. 27 2 1. 35 2. 38 3. 41 4. 43 5. 48 6. 50 3 1. 56 2. 59 3. 63 4. 65 5. 69 13 22 35 56 6. 74 7. 82 8. 84 9. 87 10. 97 11. 102 12. 107 13. 111 4 114 1. 114 2.
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 informationebook14-4
4 TINY LL(1) First F o l l o w t o p - d o w n 3 3. 3 backtracking parser predictive parser recursive-descent parsing L L ( 1 ) LL(1) parsing L L ( 1 ) L L ( 1 ) 1 L 2 L 1 L L ( k ) k L L ( 1 ) F i r s
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 information2015年计算机二级(C语言)模拟试题及答案(四)
2016 年 计 算 机 二 级 (C 语 言 ) 模 拟 试 题 及 答 案 (4) 一 填 空 题 1 C 语 言 中 基 本 的 数 据 类 型 有 : 2 C 语 言 中 普 通 整 型 变 量 的 类 型 说 明 符 为, 在 内 存 中 占 字 节, 有 符 号 普 通 整 型 的 数 据 范 围 是 3 整 数 -35 在 机 内 的 补 码 表 示 为 4 执 行 下 列 语 句 int
More information* RRB *
*9000000000RRB0010040* *9000000000RRB0020040* *9000000000RRB0030040* *9000000000RRB0040040* *9000000000RRC0010050* *9000000000RRC0020050* *9000000000RRC0030050* *9000000000RRC0040050* *9000000000RRC0050050*
More informationLorem ipsum dolor sit amet, consectetuer adipiscing elit
留 学 澳 洲 英 语 讲 座 English for Study in Australia 第 十 三 课 : 与 同 学 一 起 做 功 课 Lesson 13: Working together L1 Male 各 位 听 众 朋 友 好, 我 是 澳 大 利 亚 澳 洲 广 播 电 台 的 节 目 主 持 人 陈 昊 L1 Female 各 位 好, 我 是 马 健 媛 L1 Male L1
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 information区 域 活 动 进 入 中 班 我 们 区 域 的 设 置 和 活 动 材 料 都 有 所 变 化, 同 时 也 吸 引 孩 子 们 积 极 的 参 与 学 习 操 作 区 的 新 材 料 他 们 最 喜 欢, 孩 子 们 用 立 方 块 进 行 推 理 操 作 用 扑 克 牌 进 行 接 龙 游
日 常 生 活 本 月 我 们 日 常 生 活 活 动 的 重 点 :1. 让 孩 子 养 成 良 好 的 生 活 习 惯, 注 重 生 活 细 节 如 : 在 换 好 鞋 子 后 能 将 鞋 子 整 齐 的 摆 放 进 鞋 架 坐 在 椅 子 上 换 鞋 正 确 的 收 放 椅 子 等 2 让 孩 子 有 自 我 照 顾 的 意 识 如, 让 孩 子 感 受 自 己 的 冷 热 并 告 知 老 师,
More information( 表 1) 學 校 基 本 資 料 學 校 類 型 新 竹 市 東 區 新 竹 國 小 班 級 數 55 校 址 新 竹 市 興 學 街 106 號 電 話 傳 真 網 址
學 校 課 程 計 畫 備 查 項 目 及 表 格 新 竹 市 104 學 年 度 新 竹 國 小 課 程 計 畫 備 查 項 目 壹 學 校 課 程 發 展 與 規 劃 一 學 校 課 程 計 畫 通 過 課 程 發 展 委 員 會 審 核 之 日 期 ( 含 會 議 記 錄, 簽 到 單 ) 二 學 校 基 本 資 料 ( 表 1) 三 學 校 背 景 分 析 ( 可 自 訂 格 式, 表 2
More information