untitled

Size: px
Start display at page:

Download "untitled"

Transcription

1 ()PLD [1] Miro Samek, Ph.D Practical Statecharts in C/C++ Quantum Programming for Embedded Systems [2] OpenFans FSM Finite State Machine HSM Hierarchical State Machine OOP Object Oriented Programming UML Unified Modeling Language LSP Liskov Substitution Principle PoC push to talk over cellular

2

3 FSM FSM FSM State() Guard() Event() Action() Transition FSM FSM C Parser() Calc() HSM programming-by-difference HSM HSM OOP state inheritance and class inheritance Entry/Exit Actions and Construction/Destruction(/ /) programming-by-difference abstraction() HSM Calc Transition HSM PoC Audio Player PoC Call Control FSM nestted switch statement switch state table() i

4 7.3 Function Address As State() QFSM frame(qfsm ) HSM ii

5 2-1 Keyboard FSM in UML format Keyboard FSM in UML format C comment parser (CParser) FSM Basic Calc Example Basic Calc FSM Basic Calc FSM add Result state Basic Calc FSM add Result state and Cancel event Simple Calc HSM HSM conception substate of operandx Full Calc HSM State Tree of Calc HSM of audio Player HSM of Call Control i

6

7 1 20 David Harel UML FSM HSM FSM HSM C 1-1

8

9 2FSM 2.1 FSM 2.2 FSM State() State() Guard() guardguard Event() Event Action() EventAction() Event 2-1

10 2.2.5 Transition Transition triggering event trigger 2.3 FSM 2-1UML FSM initial transition final transition state ANY_KEY / generate lowercase code default ANY_KEY [ keystrokes > ] CAPS_LOCK CAPS_LOCK State transition capslocked ANY_KEY [ keystrokes > ] ANY_KEY / generate uppercase code Self transition guard trigger action list 2-1 Keyboard FSM in UML format 1 Statestate 2-2

11 2 FSM TransitionEvent [guard]/action Initial Transition Initial TransitionFSM initial transitionevent action Final Transition FSM Internal Transition UML state state internal-transition Keyboard FSM in UML format 2 2-3

12

13 3FSM 2 FSM 3.1 C Parser().C.C C /* *//* */ code// (1) a = b * c / d; /* calc expression is b*c/d. **/ (2) Event CHAR SLASH STAR (3) Initial Transition code idle code (4) state transition code CHAR STAR code SLASH SLASH slash slash STAR STAR comment CHAR SLASH SLASH code code comment code star slash 3-1

14 SLASH code CHAR, STAR CHAR SLASH star slash STAR CHAR STAR STAR SLASH comment CHAR, SLASH 3-1 C comment parser (CParser) FSM 3.2 Calc() operand1 operator operand2 '=' operand1 operand2 + - * /C CEClear Entry

15 3 FSM 3-2 Basic Calc Example 1 expression ::= operand1 operator operand2 '=' 2 operand1 ::= expression ['+' ' '] number 3 operand2 ::= ['+' ' '] number 4 number ::= {'0' '1'... '9'* ['.' {'0' '1'... '9'*] 5 operator ::= '+' ' ' '*' '/' (1) operand1 operator operand2 '=' 1+2= operand1 1 OpEntered operand

16 (2) Initial Transition operand1 (3) Event Transition operand1 operator+ - * / opentered operand20~9 operand2 operand2 operand1 = operand1 3-3 operand1 PLUS, MINUS, MULTIPLY, DIVIDE opentered EQUALS 0~9, POINT operand2 3-3 Basic Calc FSM (4) 3-3= operand1 3-4

17 3 FSM resultresult3 1) operatoroperand1 2) Cancel 3) operand * /OPER operand1 0~9, POINT OPER C opentered OPER result 0~9, POINT EQUALS operand2 3-4 Basic Calc FSM add Result state (5) 3-4Cancelresult Cancel

18 3-5 Basic Calc FSM add Result state and Cancel event (6) 3-5Cancel HSM FSMFSM HSM

19 3 FSM Calc operand1 OPER 0~9, POINT C opentered OPER result 0~9, POINT EQUALS operand2 3-6 Simple Calc HSM HSM 3-7

20

21 4HSM 4.1 programming-by-difference HSM programming-by-difference 4-1 GUI system GUI MS-Windows GUI GUI GUI MS-Windows MS-Windows GUI GUI look and feel David Harel FSM HSM 4.2 HSM HSM 4-2 A) 4-2 B) 2-1, 2-2 superstate substate 4-1

22 4-2 HSM conception Event Event substate substate Event superstate 4.3 HSM OOP HSM OOP OOP 3 abstraction inheritancepolymorphism state inheritance and class inheritance OOP class inheritance behavioral inheritance 4-2 substate superstate substate superstate, substate superstate 4-2

23 4 HSM failed substate unsafe unsafe failed is-in-a-state is-a-kind-of 4-3 Example of HSM Entry/Exit Actions and Construction/Destruction(/ /) Entry Exit ConstructionDestruction Construction Destruction Entry Exit programming-by-difference 4-3

24 4.3.4 abstraction() OOP HSM zoom in zoom out 4-4

25 5HSM HSM 5.1 Calc Calc HSM (7) operand1 operand2 0 operandx substate of operandx (8) CECancel Entry Calc HSM

26 C IDCANCEL Calc ready negated1 Entry/ result begin OPER[keyid == PLUS] OPER[keyid==MINUS] CE Entry/ CE POINT POINT operand1 OPER zero1 int1 1~9 POINT 0/ 1...9/ 0/ 1...9/ frac1 EQUALS POINT OPER opentered OPER[keyid==MINUS] nagated2 CE Entry/ OPER CE POINT POINT operand2 zero2 int2 1~9 POINT 0/ 1...9/ 0/ 1...9/ frac2 POINT 5-2

27 5 HSM 5-2 Full Calc HSM 5-2 zoom inzoom out level HSM 5.2 Liskov Substitution Principle LSPLSP LSP LSP HSM Event Action Transition, LSP LSP HSM LSP zoom out 5-3

28 LSP 1988 B. Meyer Design by ContractDBC 1) (Pre-condition) 2) (Post-condition) 3) (Invariant) LSP LSP 5-2 LSP begin OPER[key==MINUS] ready OPER LSP Transition entry/exit HSM FSM 5-2 state

29 5 HSM 5-3 State Tree of Calc least common ancestorlca LCA exit transition action LCA entry int2 result int2 exitoperand2 exit ready entryresult entry 5-5

30 6HSM PoC HSM 6.1 PoC Audio Player audio player audio handle audio buffer audio audio playerplay audio R:ReceiveS:Send (1) Initial transitionidle (2) idlepoc_audio_start_play_req dejitter (3) dejitter timertimeraudio handle bufferaudio StartPlay POC_AUDIO_PLAY_OK_INDdejitter buffer guard PlayDone internal-transition (4) PlayDonePOC_AUDIO_START_PLAY_REQ StartPlay 6-6

31 6 HSM (5) PlayingStartPlay PlayDonePOC_STOP_PLAY_REQ audio handlelsp (6) audiostartplay POC_SPEECH_PLAYER_SET_PARAM_REQ audio Player internal-transition Player R:POC_SPEECH_PLAYER_SET_PARAM_REQ/ Idle R:POC_CLOSE_PLAYER_HANDLE_CNF / ClosePlayerHandle R:POC_STOP_PLAY_REQ R:POC_AUDIO_START_PLAY_REQ / R:POC_AUDIO_PLAYER_STOP_CNF / POCADAP_AudioClosePlayerHandle() Dejitter Entry/StartTimer Exit/StopTimer StopPlay R:POC_DEJITTER_TIME_OUT_IND / POCADAP_AudioCreatePlayerHandle() And POCADAP_AudioStartPlay() R:POC_STOP_PLAY_REQ / POCADAP_AudioStopPlay() Playing StartPlay R:POC_AUDIO_PLAY_OK_IND / FreePlayedData() and If (has_data_to_play) POCADAP_AudioSetDataAndPlay() R:POC_SPEECH_PLAYER_SET_PARAM_REQ/ POCADAP_AudioSetPlayerParams R:POC_AUDIO_PLAY_OK_IND / FreePlayedData() and If (has_no_data_to_play) R:POC_SPEECH_PLAY_REQ / If (has_data_to_play) POCADAP_AudioSetDataAndPlay() PlayDone R:POC_AUDIO_START_PLAY_REQ / If (has_no_data_to_play) 6-1 HSM of audio Player POC_STOP_PLAY_REQ POC_SPEECH_PLAYER_SET_PARAM_REQ 6.2 PoC Call Control Call Control (SIP POC ) 6-7

32 Call R:POC_MOCALL_REQ Idle R:SIP_CALL_DISCONNECT_IND / S:POC_CALL_DISCONNECT_IND And S:POC_CP_SESSION_RELEASE_IND R:SIP_LEAVE_CALL_OK_CNF / S:POC_CALL_DISCONNECT_IND And Enter RelResource R:POC_MOCALL_REQ / POCADAP_SIPMakeCall() R:SIP_MTCALL_IND / R:SIP_TEMP_UNAVAILABLE_IND S:POC_MTCALL_IND / Or R:SIP_REQUEST_TIME_OUT / Or R:SIP_MOCALL_FAIL_CNF / S:POC_MOCALL_ESTABLISH_FAIL_IND R:POC_REJECT_MTCALL_RSP / POCADAP_SIPRejectCall() R: POC_PENDING_MT_TIME_OUT_IND/ S:POC_MTCALL_ESTABLISH_FAIL_IND POCADAP_SIPMTCallTimeOut() IncomingMT PendingRelease PendingMO R:SIP_CALL_TRYING_IND/ S:POC_MOCALL_PROCESSING_IND SIP_CALL_RINGING_IND/ S:POC_MOCALL_RINGING_IND Entry/ StartTimer Exi/ StopTimer R:POC_ANSWER_MTCALL_RSP / POCADAP_SIPAnswerCall() PendingMTAnswer R:POC_LEAVE_CALL_REQ/ POCADAP_SIPLeaveCall() And S:POC_CP_SESSION_REL_STEP1_IND R:SIP_MOCALL_OK_CNF / S: POC_MOCALL_ESTABLISH_CNF And S:POC_CP_MO_ESTABLISH_IND R:SIP_MTCALL_ACK / S:POC_MTCALL_ESTABLISH_CNF And S:POC_CP_MT_ESTABLISH_IND Estab R:SIP_REFRESH_SESSION_IND/ POCADAP_SIPRefreshSession() R:SIP_LEAVE_CALL_IND/S:POC_LEAVE_CALL_IND 6-2 HSM of Call Control (1)POC_MOCALL_REQ HSM PendingRelease Callaction (2) SIP_CALL_DISCONNECT_INDidleevent 6-8

33 7FSM FSM C CParser FSM 3-1 dispatch state transition Initial Transition CLASS SUBCLASS C++ 2 C STRUCTURE 7.1 nestted switch statement switch Cparser1.h enum Signal { /* enumeration for CParser signals */ CHAR_SIG, STAR_SIG, SLASH_SIG ; enum State { /* enumeration for CParser states */ CODE, SLASH, COMMENT, STAR ; struct CParser1 { enum State state ; /* the scalar state-variable */ long commentctr ; /* comment character counter */ /*... */ /* other CParser1 attributes */ ; #define CParser1Tran(me_, target_) ((me_)->state = target_) Cparser1.c void CParser1Dispatch(CParser1 *me, unsigned const sig) { switch (me->state ) { case CODE: switch (sig) { case SLASH_SIG: CParser1Tran(me, SLASH); /* transition to "slash" */ case SLASH: switch (sig) { case STAR_SIG: me->commentctr += 2; /* SLASH-STAR count as comment */ CParser1Tran(me, COMMENT); /* transition to "comment" */ case CHAR_SIG: CParser1Tran(me, CODE); /* go back to "code" */ case COMMENT: switch (sig) { 7-1

34 case STAR_SIG: CParser1Tran(me, STAR); /* transition to "star" */ case CHAR_SIG: case SLASH_SIG: ++me->commentctr ; /* count the comment char */ case STAR: switch (sig) { case STAR_SIG: ++me->commentctr ; /* count STAR as comment */ case SLASH_SIG: me->commentctr += 2; /* count STAR-SLASH as comment */ CParser1Tran(me, CODE); /* transition to "code" */ case CHAR_SIG: me->commentctr += 2; /* count STAR-? as comment */ CParser1Tran(me, COMMENT); /* go back to "comment" */ FSM 2 switch case switch case switch case 7.2 state table() Cparser2.h CLASS(Tran) Action action; unsigned nextstate; METHODS END_CLASS enum State { /* enumeration for CParser states */ CODE, SLASH, COMMENT, STAR, MAX_STATE ; Cparser2.c void StateTableDispatch(StateTable *me, unsigned const sig) { register Tran const *t = me->table + 7-2

35 7 FSM me->state *me->nsignals + sig; (t->action)(me); me->state = t->nextstate; void StateTableDoNothing(StateTable *me) { static Tran const loctable[max_state][max_sig] = { {{StateTableDoNothing, CODE, {StateTableDoNothing, CODE, {StateTableDoNothing, SLASH, {{StateTableDoNothing, CODE, {(Action)CParserA2, COMMENT, {StateTableDoNothing, CODE, {{(Action)CParserA1, COMMENT, {StateTableDoNothing,STAR, {(Action)CParserA1, COMMENT, {{(Action)CParserA2, COMMENT, {(Action)CParserA1, STAR, {(Action)CParserA2, CODE ; void CParserA1(CParser2 *me) { me->commentctr += 1; void CParserA2(CParser2 *me) { me->commentctr += 2; FSM nestted switch statement state event 2 action transition 7.3 Function Address As State() Cparser4.h typedef void /* return value */ (*State) /* pointer-to-member name */ (Fsm *me, /* class the function pointer is a member of */ unsigned const sig); /* the rest of the argument list */ struct Fsm { State state_; /* protected current state */ ; #define FsmDispatch(me_, sig_) ((*(me_)->state_)((me_), sig)) #define TRAN(target_) (((Fsm *)me)->state_ = (State)(target_)) EntryExit 7-3

36 #define TRAN(target_) do{ \ *((Fsm *)me)->state_)((me), EXIT_SIG); \ ((Fsm *)me)->state = (State)(target_); \ *((Fsm *)me)->state_)((me), ENTRY_SIG); \ while(0) Cparser4.c void CParser4code(CParser4 *me, unsigned const sig) { switch (sig) { case SLASH_SIG: TRAN(CParser4slash); /* transition to "slash" */ void CParser4slash(CParser4 *me, unsigned const sig) { switch (sig) { case STAR_SIG: me->commentctr += 2; /* SLASH-STAR chars count as comment */ TRAN(CParser4comment); /* transition to "comment" */ case CHAR_SIG: TRAN(CParser4code); /* go back to "code" */ void CParser4comment(CParser4 *me, unsigned const sig) { static const void (*lookup[])(cparser4 *) = { CParser4commentOnCHAR, CParser4commentOnSTAR, CParser4commentOnSLASH ; REQUIRE(sig <= SLASH_SIG); /* signal must be in range */ (*lookup[sig])(me); /* rapidly dispatch without 'switch' */ void CParser4star(CParser4 *me, unsigned const sig) { switch (sig) { case STAR_SIG: ++me->commentctr ; /* count '*' as comment character */ case CHAR_SIG: me->commentctr += 2; /* count STAR-? as comment */ TRAN(CParser4comment); /* go back to "comment" */ case SLASH_SIG: me->commentctr += 2; /* count STAR-SLASH as comment */ TRAN(CParser4code); /* transition to "code" */ FSM state (State) CParser4slash() CParser4slash slash 7-4

37 7 FSM event FsmDispatch() state entry/exit nestted switch statement state table 7.4 QFSM frame(qfsm ) qfsm.h SUBCLASS(QFsm, Object) /* Quantum Finite State Machine base class */ QFsmState state ; /* the active state */ VTABLE(QFsm, Object) #define QFsmDispatch(me_, e_) (*(me_)->state )((me_), (e_)) #define QFSM_TRAN(target_) \ (((QFsm *)me)->state = (QFsmState)(target_)) EntryExit QFSM_TRAN(me, target_) do{\ { \ QEvent e; \ e.sig = EXIT_SIG; \ (*(me)->state )((me), (e_)); \ ((QFsm *)me)->state = (QFsmState)(target_); \ e.sig = ENTRY_SIG; \ (*(me_)->state )((me), (e_)); \ while(0) Cparser5.h #include qfsm.h enum Event { /* enumeration for CParser events */ CHAR_SIG = Q_USER_SIG, STAR_SIG, SLASH_SIG ; SUBCLASS(CParser5, QFsm) long commentctr ; /* comment character counter */ METHODS CParser5 *CParser5Ctor(CParser5 *me); /* Ctor */ void CParser5initial(CParser5 *me, QEvent const *e); void CParser5code(CParser5 *me, QEvent const *e); void CParser5slash(CParser5 *me, QEvent const *e); void CParser5comment(CParser5 *me, QEvent const *e); void CParser5star(CParser5 *me, QEvent const *e); #define CParser5GetCommentCtr(me_) ((me_)->commentctr ) END_CLASS 7-5

38 Cparser5.c void CParser5code(CParser5 *me, QEvent const *e) { switch (e->sig) { case SLASH_SIG: QFSM_TRAN(CParser5slash); /* transition to "slash" */ void CParser5slash(CParser5 *me, QEvent const *e) { switch (e->sig) { case STAR_SIG: me->commentctr += 2; /* SLASH-STAR count as comment */ QFSM_TRAN(CParser5comment); /* transition to "comment" */ case CHAR_SIG: QFSM_TRAN(CParser5code); /* go back to "code" */ void CParser5comment(CParser5 *me, QEvent const *e) { switch (e->sig) { case STAR_SIG: QFSM_TRAN(CParser5star); /* transition to "star" */ case CHAR_SIG: case SLASH_SIG: ++me->commentctr ; /* count the comment character */ void CParser5star(CParser5 *me, QEvent const *e) { switch (e->sig) { case STAR_SIG: ++me->commentctr ; /* count '*' as comment character */ case CHAR_SIG: me->commentctr += 2; /* count STAR-? as comment */ QFSM_TRAN(CParser5comment); /* go back to "comment" */ case SLASH_SIG: me->commentctr += 2; /* count STAR-SLASH as comment */ QFSM_TRAN(CParser5code); /* transition to "code" */ QFSM Function Address As State fsm framework qfsm.h qfsm.c Miro Samek, Ph.D FSM UML code entry/exit 7-6

39 7 FSM 7-7

40

41 8HSM qhsm.h Calc HSM 5-2 QHSM QFSM initial transition SUBCLASS(QHsm, Object) /* Hierarchical State Machine base class */ QState state ; /* the active state */ QState source ; /* source state during a transiton */ VTABLE(QHsm, Object) void QHsmDispatch(QHsm *me, QEvent const *e); /* take RTC step */ #define Q_TRAN(target_) if (1) { \ static Tran_ t_; \ QHsmTranStat_((QHsm *)me, &t_, (QState)(target_));\ #define Q_TRAN_DYN(target_) \ QHsmTran_((QHsm *)me, (QState)(target_)) calc.h #include "qhsm.h" SUBCLASS(CalcEvt, QEvent) int keyid; /* ID of the key depressed */ METHODS END_CLASS SUBCLASS(Calc, QHsm) HWND hwnd_; /* the calculator window handle */ BOOL ishandled_; char display_[40]; char *ins_; double operand1_; double operand2_; int operator_; METHODS Calc *CalcCtor(Calc *me); void CalcXtor(Calc *me); Calc *CalcInstance(int id); /* static Singleton accessor method */ void Calc_initial(Calc *me, QEvent const *e); QSTATE Calc_calc(Calc *me, QEvent const *e); QSTATE Calc_ready(Calc *me, QEvent const *e); QSTATE Calc_result(Calc *me, QEvent const *e); QSTATE Calc_begin(Calc *me, QEvent const *e); QSTATE Calc_negated1(Calc *me, QEvent const *e); QSTATE Calc_operand1(Calc *me, QEvent const *e); QSTATE Calc_zero1(Calc *me, QEvent const *e); QSTATE Calc_int1(Calc *me, QEvent const *e); QSTATE Calc_frac1(Calc *me, QEvent const *e); QSTATE Calc_opEntered(Calc *me, QEvent const *e); QSTATE Calc_negated2(Calc *me, QEvent const *e); QSTATE Calc_operand2(Calc *me, QEvent const *e); QSTATE Calc_zero2(Calc *me, QEvent const *e); QSTATE Calc_int2(Calc *me, QEvent const *e); QSTATE Calc_frac2(Calc *me, QEvent const *e); 8-1

42 void CalcClear_(Calc *me); void CalcInsert_(Calc *me, int keyid); void CalcNegate_(Calc *me); void CalcEval_(Calc *me); void CalcDispState(Calc *me, char const *s); END_CLASS calc.c QFSMstate QSTATE Calc_ready(Calc *me, QEvent const *e) { BOOLEAN is_handled = TRUE; switch (e->sig) { case Q_ENTRY_SIG: CalcDispState(me, "ready"); case Q_INIT_SIG: Q_INIT(Calc_begin); case IDC_0: CalcClear_(me); Q_TRAN_DYN(Calc_zero1); case IDC_1_9: CalcClear_(me); CalcInsert_(me, ((CalcEvt *)e)->keyid); Q_TRAN_DYN(Calc_int1); case IDC_POINT: CalcClear_(me); CalcInsert_(me, IDC_0); CalcInsert_(me, ((CalcEvt *)e)->keyid); Q_TRAN_DYN(Calc_frac1); case IDC_OPER: sscanf(me->display_, "%lf", &me->operand1_); me->operator_ = ((CalcEvt *)e)->keyid; Q_TRAN_DYN(Calc_opEntered); default: is_handled = FALSE; if (is_handled) { return 0; else { return (QSTATE)Calc_calc; QHSM HSM qhsm.h qhsm.c QFSM frame 8-2

43 8 HSM HSM FSM ready Calc_ready QHSM HSM 2) SUPERCLASS QHsm Calc HSM instance QF 3) 0 ready event IDC_0 0 event Calc_calc Calc QF QTop() 4) QF Q_EMPTY_SIG = 0, // Q_INIT_SIG = 1,//initial transition readybeginstate transitionready begin Q_ENTRY_SIG = 2, //Entry Q_EXIT_SIG = 3 //Exit 5) Transition Q_TRAN_DYN QF Q_EXIT_SIG Q_ENTRY_SIG UML QHSM QHSM 8-3

44

45 9 CParser Calc SampleCode.rar 1

CC213

CC213 : (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 information

2/80 2

2/80 2 2/80 2 3/80 3 DSP2400 is a high performance Digital Signal Processor (DSP) designed and developed by author s laboratory. It is designed for multimedia and wireless application. To develop application

More information

Microsoft Word - 物件導向編程精要.doc

Microsoft Word - 物件導向編程精要.doc Essential Object-Oriented Programming Josh Ko 2007.03.11 object-oriented programming C++ Java OO class object OOP Ruby duck typing complexity abstraction paradigm objects objects model object-oriented

More information

C/C++语言 - 运算符、表达式和语句

C/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

untitled

untitled 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 information

Microsoft Word - ch04三校.doc

Microsoft Word - ch04三校.doc 4-1 4-1-1 (Object) (State) (Behavior) ( ) ( ) ( method) ( properties) ( functions) 4-2 4-1-2 (Message) ( ) ( ) ( ) A B A ( ) ( ) ( YourCar) ( changegear) ( lowergear) 4-1-3 (Class) (Blueprint) 4-3 changegear

More information

C/C++ - 函数

C/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

FY.DOC

FY.DOC 高 职 高 专 21 世 纪 规 划 教 材 C++ 程 序 设 计 邓 振 杰 主 编 贾 振 华 孟 庆 敏 副 主 编 人 民 邮 电 出 版 社 内 容 提 要 本 书 系 统 地 介 绍 C++ 语 言 的 基 本 概 念 基 本 语 法 和 编 程 方 法, 深 入 浅 出 地 讲 述 C++ 语 言 面 向 对 象 的 重 要 特 征 : 类 和 对 象 抽 象 封 装 继 承 等 主

More information

Microsoft Word - 第3章.doc

Microsoft 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

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

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 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

C/C++ - 字符输入输出和字符确认

C/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 information

C/C++ - 文件IO

C/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言語

新・解きながら学ぶ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

Fun 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

Fun 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

Important Notice SUNPLUS TECHNOLOGY CO. reserves the right to change this documentation without prior notice. Information provided by SUNPLUS TECHNOLO

Important Notice SUNPLUS TECHNOLOGY CO. reserves the right to change this documentation without prior notice. Information provided by SUNPLUS TECHNOLO Car DVD New GUI IR Flow User Manual V0.1 Jan 25, 2008 19, Innovation First Road Science Park Hsin-Chu Taiwan 300 R.O.C. Tel: 886-3-578-6005 Fax: 886-3-578-4418 Web: www.sunplus.com Important Notice SUNPLUS

More information

新版 明解C++入門編

新版 明解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 information

Microsoft Word - 01.DOC

Microsoft Word - 01.DOC 第 1 章 JavaScript 简 介 JavaScript 是 NetScape 公 司 为 Navigator 浏 览 器 开 发 的, 是 写 在 HTML 文 件 中 的 一 种 脚 本 语 言, 能 实 现 网 页 内 容 的 交 互 显 示 当 用 户 在 客 户 端 显 示 该 网 页 时, 浏 览 器 就 会 执 行 JavaScript 程 序, 用 户 通 过 交 互 式 的

More information

新・明解C言語入門編『索引』

新・明解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 information

新版 明解C言語入門編

新版 明解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 information

新・解きながら学ぶJava

新・解きながら学ぶ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 information

CHAPTER 1

CHAPTER 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 information

int *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++;

int *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

1 4 1.1 4 1.2..4 2..4 2.1..4 3.4 3.1 Java.5 3.1.1..5 3.1.2 5 3.1.3 6 4.6 4.1 6 4.2.6 5 7 5.1..8 5.1.1 8 5.1.2..8 5.1.3..8 5.1.4..9 5.2..9 6.10 6.1.10

1 4 1.1 4 1.2..4 2..4 2.1..4 3.4 3.1 Java.5 3.1.1..5 3.1.2 5 3.1.3 6 4.6 4.1 6 4.2.6 5 7 5.1..8 5.1.1 8 5.1.2..8 5.1.3..8 5.1.4..9 5.2..9 6.10 6.1.10 Java V1.0.1 2007 4 10 1 4 1.1 4 1.2..4 2..4 2.1..4 3.4 3.1 Java.5 3.1.1..5 3.1.2 5 3.1.3 6 4.6 4.1 6 4.2.6 5 7 5.1..8 5.1.1 8 5.1.2..8 5.1.3..8 5.1.4..9 5.2..9 6.10 6.1.10 6.2.10 6.3..10 6.4 11 7.12 7.1

More information

C/C++ - 字符串与字符串函数

C/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 information

CHAPTER VC#

CHAPTER 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

c_cpp

c_cpp C C++ C C++ C++ (object oriented) C C++.cpp C C++ C C++ : for (int i=0;i

More information

C/C++程序设计 - 字符串与格式化输入/输出

C/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 information

Computer Architecture

Computer Architecture ECE 3120 Computer Systems Assembly Programming Manjeera Jeedigunta http://blogs.cae.tntech.edu/msjeedigun21 Email: msjeedigun21@tntech.edu Tel: 931-372-6181, Prescott Hall 120 Prev: Basic computer concepts

More information

epub83-1

epub83-1 C++Builder 1 C + + B u i l d e r C + + B u i l d e r C + + B u i l d e r C + + B u i l d e r 1.1 1.1.1 1-1 1. 1-1 1 2. 1-1 2 A c c e s s P a r a d o x Visual FoxPro 3. / C / S 2 C + + B u i l d e r / C

More information

國家圖書館典藏電子全文

國家圖書館典藏電子全文 EAI EAI Middleware EAI 3.1 EAI EAI Client/Server Internet,www,Jav a 3.1 EAI Message Brokers -Data Transformation Business Rule XML XML 37 3.1 XML XML XML EAI XML 1. XML XML Java Script VB Script Active

More information

untitled

untitled 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 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 information

extend

extend (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 information

untitled

untitled 不 料 料 例 : ( 料 ) 串 度 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 information

416 Journal of Software 4(3) 2003,1. Java, Java, Java : ; ; ;Java : TP311 : A (binding time analysis ), (partial evaluation)., [1~3]., C Java, Java.,.

416 Journal of Software 4(3) 2003,1. Java, Java, Java : ; ; ;Java : TP311 : A (binding time analysis ), (partial evaluation)., [1~3]., C Java, Java.,. 1000-9825/2003/14(03)0415 2003 Journal of Software Vol.14, No.3 +,, (, 100022) A Technology of Binding Time Analysis for Object-Oriented Programming Languages LIAO Hu-Sheng +, TONG Zhao-Feng, WANG Zhong

More information

WWW PHP Comments Literals Identifiers Keywords Variables Constants Data Types Operators & Expressions 2

WWW 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 information

C 1

C 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

C/C++语言 - C/C++数据

C/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 information

C/C++语言 - 分支结构

C/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 information

1 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

1 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

ebook14-4

ebook14-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 information

PTS7_Manual.PDF

PTS7_Manual.PDF User Manual Soliton Technologies CO., LTD www.soliton.com.tw - PCI V2.2. - PCI 32-bit / 33MHz * 2 - Zero Skew CLK Signal Generator. - (each Slot). -. - PCI. - Hot-Swap - DOS, Windows 98/2000/XP, Linux

More information

C/C++ 语言 - 循环

C/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 information

mvc

mvc Build an application Tutor : Michael Pan Application Source codes - - Frameworks Xib files - - Resources - ( ) info.plist - UIKit Framework UIApplication Event status bar, icon... delegation [UIApplication

More information

INTRODUCTION TO COM.DOC

INTRODUCTION TO COM.DOC How About COM & ActiveX Control With Visual C++ 6.0 Author: Curtis CHOU mahler@ms16.hinet.net This document can be freely release and distribute without modify. ACTIVEX CONTROLS... 3 ACTIVEX... 3 MFC ACTIVEX

More information

C语言的应用.PDF

C语言的应用.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 information

C PICC C++ C++ C C #include<pic.h> C static volatile unsigned char 0x01; static volatile unsigned char 0x02; static volatile unsigned cha

C 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 information

02

02 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

51 C 51 isp 10 C PCB C C C C KEIL

51 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 information

Wy159.mps

Wy159.mps 第 章 系 统 开 发 方 法 管 理 信 息 系 统 开 发 的 效 率 质 量 成 本 及 用 户 的 满 意 程 度, 除 了 管 理 技 术 等 因 素 外, 还 与 系 统 开 发 方 法 密 切 相 关 管 理 信 息 系 统 从 产 生 到 现 在 已 经 发 展 了 许 多 开 发 方 法, 这 些 开 发 方 法 各 自 遵 循 一 定 的 基 本 思 想, 适 用 于 一 定 的

More information

Microsoft Word - 970617cppFinalSolution.doc

Microsoft Word - 970617cppFinalSolution.doc 國 立 台 灣 海 洋 大 學 資 訊 工 程 系 C++ 程 式 設 計 期 末 考 參 考 答 案 姓 名 : 系 級 : 學 號 : 97/06/17 考 試 時 間 :10:00 12:10 試 題 敘 述 蠻 多 的, 看 清 楚 題 目 問 什 麼, 針 對 重 點 回 答 是 很 重 要 的 ; 不 確 定 的 請 一 定 要 當 場 提 出 來, 不 要 白 花 力 氣 在 誤 會

More information

ebook

ebook 3 3 3.1 3.1.1 ( ) 90 3 1966 B e r n s t e i n P ( i ) R ( i ) W ( i P ( i P ( j ) 1) R( i) W( j)=φ 2) W( i) R( j)=φ 3) W( i) W( j)=φ 3.1.2 ( p r o c e s s ) 91 Wi n d o w s Process Control Bl o c k P C

More information

Windows 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 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 information

untitled

untitled 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

科学计算的语言-FORTRAN95

科学计算的语言-FORTRAN95 科 学 计 算 的 语 言 -FORTRAN95 目 录 第 一 篇 闲 话 第 1 章 目 的 是 计 算 第 2 章 FORTRAN95 如 何 描 述 计 算 第 3 章 FORTRAN 的 编 译 系 统 第 二 篇 计 算 的 叙 述 第 4 章 FORTRAN95 语 言 的 形 貌 第 5 章 准 备 数 据 第 6 章 构 造 数 据 第 7 章 声 明 数 据 第 8 章 构 造

More information

coverage2.ppt

coverage2.ppt Satellite Tool Kit STK/Coverage STK 82 0715 010-68745117 1 Coverage Definition Figure of Merit 2 STK Basic Grid Assets Interval Description 3 Grid Global Latitude Bounds Longitude Lines Custom Regions

More information

D C 93 2

D C 93 2 D9223468 3C 93 2 Java Java -- Java UML Java API UML MVC Eclipse API JavadocUML Omendo PSPPersonal Software Programming [6] 56 8 2587 56% Java 1 epaper(2005 ) Java C C (function) C (reusability) eat(chess1,

More information

untitled

untitled Ogre Rendering System http://antsam.blogone.net AntsamCGD@hotmail.com geometry systemmaterial systemshader systemrendering system API API DirectX OpenGL API Pipeline Abstraction API Pipeline Pipeline configurationpipeline

More information

Microsoft PowerPoint - ch6 [相容模式]

Microsoft PowerPoint - ch6 [相容模式] UiBinder wzyang@asia.edu.tw UiBinder Java GWT UiBinder XML UI i18n (widget) 1 2 UiBinder HelloWidget.ui.xml: UI HelloWidgetBinder HelloWidget.java XML UI Owner class ( Composite ) UI XML UiBinder: Owner

More information

第 15 章 程 式 編 写 語 言 15.1 程 式 編 写 語 言 的 角 色 程 式 編 寫 語 言 是 程 式 編 寫 員 與 電 腦 溝 通 的 界 面 語 法 是 一 組 規 則 讓 程 式 編 寫 員 將 字 詞 集 合 起 來 電 腦 是 處 理 位 元 和 字 節 的 機 器, 與

第 15 章 程 式 編 写 語 言 15.1 程 式 編 写 語 言 的 角 色 程 式 編 寫 語 言 是 程 式 編 寫 員 與 電 腦 溝 通 的 界 面 語 法 是 一 組 規 則 讓 程 式 編 寫 員 將 字 詞 集 合 起 來 電 腦 是 處 理 位 元 和 字 節 的 機 器, 與 程 式 編 写 語 言 在 完 成 這 章 後, 你 將 能 夠 了 解 程 式 編 写 語 言 的 功 能 了 解 高 階 語 言 和 低 階 語 言 之 間 的 分 別 知 道 翻 譯 程 式 的 意 義 和 能 夠 把 翻 譯 程 式 分 類 為 : 匯 編 程 式 編 譯 程 式 和 解 譯 程 式 認 識 不 同 翻 譯 程 式 的 優 點 和 缺 點 程 式 是 指 揮 電 腦 的 指

More information

OOAD PowerDesigner OOAD Applying PowerDesigner CASE Tool in OOAD PowerDesigner CASE Tool PowerDesigner PowerDesigner CASE To

OOAD PowerDesigner OOAD Applying PowerDesigner CASE Tool in OOAD PowerDesigner CASE Tool PowerDesigner PowerDesigner CASE To PowerDesigner Applying PowerDesigner CASE Tool in OOAD albertchung@mpinfo.com.tw PowerDesigner CASE Tool PowerDesigner PowerDesigner CASE Tool PowerDesigner CASE Tool CASE Tool PowerDesignerUnified ProcessUMLing

More information

untitled

untitled 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 information

C C

C 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 information

Microsoft Word - 3D手册2.doc

Microsoft Word - 3D手册2.doc 第 一 章 BLOCK 前 处 理 本 章 纲 要 : 1. BLOCK 前 处 理 1.1. 创 建 新 作 业 1.2. 设 定 模 拟 控 制 参 数 1.3. 输 入 对 象 数 据 1.4. 视 图 操 作 1.5. 选 择 点 1.6. 其 他 显 示 窗 口 图 标 钮 1.7. 保 存 作 业 1.8. 退 出 DEFORMTM3D 1 1. BLOCK 前 处 理 1.1. 创 建

More information

untitled

untitled OGRE http://antsam.blogone.net AntsamCGD@hotmail.com OGRE OGRE listener listener target listener target Dispatcher Processor Input Reader Event class view Event Class view Input Event ctrlaltshift ascoll

More information

RUN_PC連載_8_.doc

RUN_PC連載_8_.doc PowerBuilder 8 (8) Web DataWindow ( ) DataWindow Web DataWindow Web DataWindow Web DataWindow PowerDynamo Web DataWindow / Web DataWindow Web DataWindow Wizard Web DataWindow Web DataWindow DataWindow

More information

untitled

untitled 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

1 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 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 information

Microsoft Word - PHP7Ch01.docx

Microsoft Word - PHP7Ch01.docx PHP 01 1-6 PHP PHP HTML HTML PHP CSSJavaScript PHP PHP 1-6-1 PHP HTML PHP HTML 1. Notepad++ \ch01\hello.php 01: 02: 03: 04: 05: PHP 06:

More information

Strings

Strings Inheritance Cheng-Chin Chiang Relationships among Classes A 類 別 使 用 B 類 別 學 生 使 用 手 機 傳 遞 訊 息 公 司 使 用 金 庫 儲 存 重 要 文 件 人 類 使 用 交 通 工 具 旅 行 A 類 別 中 有 B 類 別 汽 車 有 輪 子 三 角 形 有 三 個 頂 點 電 腦 內 有 中 央 處 理 單 元 A

More information

untitled

untitled 1 Outline 料 類 說 Tang, Shih-Hsuan 2006/07/26 ~ 2006/09/02 六 PM 7:00 ~ 9:30 聯 ives.net@gmail.com www.csie.ntu.edu.tw/~r93057/aspnet134 度 C# 力 度 C# Web SQL 料 DataGrid DataList 參 ASP.NET 1.0 C# 例 ASP.NET 立

More information

ebook50-15

ebook50-15 15 82 C / C + + Developer Studio M F C C C + + 83 C / C + + M F C D L L D L L 84 M F C MFC DLL M F C 85 MFC DLL 15.1 82 C/C++ C C + + D L L M F C M F C 84 Developer Studio S t u d i o 292 C _ c p l u s

More information

基于CDIO一体化理念的课程教学大纲设计

基于CDIO一体化理念的课程教学大纲设计 Java 语 言 程 序 设 计 课 程 教 学 大 纲 Java 语 言 程 序 设 计 课 程 教 学 大 纲 一 课 程 基 本 信 息 1. 课 程 代 码 :52001CC022 2. 课 程 名 称 :Java 语 言 程 序 设 计 3. 课 程 英 文 名 称 :Java Programming 4. 课 程 类 别 : 理 论 课 ( 含 实 验 上 机 或 实 践 ) 5. 授

More information

nooog

nooog 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 information

Microsoft PowerPoint - STU_EC_Ch08.ppt

Microsoft PowerPoint - STU_EC_Ch08.ppt 樹德科技大學資訊工程系 Chapter 8: Counters Shi-Huang Chen Fall 2010 1 Outline Asynchronous Counter Operation Synchronous Counter Operation Up/Down Synchronous Counters Design of Synchronous Counters Cascaded Counters

More information

EJB-Programming-3.PDF

EJB-Programming-3.PDF :, JBuilder EJB 2.x CMP EJB Relationships JBuilder EJB Test Client EJB EJB Seminar CMP Entity Beans Value Object Design Pattern J2EE Design Patterns Value Object Value Object Factory J2EE EJB Test Client

More information

Chapter 24 DC Battery Sizing

Chapter 24  DC Battery Sizing 26 (Battery Sizing & Discharge Analysis) - 1. 2. 3. ETAP PowerStation IEEE 485 26-1 ETAP PowerStation 4.7 IEEE 485 ETAP PowerStation 26-2 ETAP PowerStation 4.7 26.1 (Study Toolbar) / (Run Battery Sizing

More information

( CIP) /. :, ( ) ISBN TP CIP ( 2005) : : : : * : : 174 ( A ) : : ( 023) : ( 023)

( 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

obj-c_4.key

obj-c_4.key Objective-C Language Tutor : Michael Hello Obj-C #import int main(int argc, const char * argv []){ NSAutoreleasePool* pool = [[NSAutoreleasePool alloc ] init]; NSLog(@"hello obj-c");

More information

csg(1_29)cs.p65

csg(1_29)cs.p65 DP-80F 2 2 3 4 5 4 5 2 3 4 5 3 ENERGY STAR ENERGY STAR ENERGY STAR 4 3 3 4 7 7 8 8 8 9 0 2 2 3 4 6 7 8 8 9 20 2 22 23 23 24 26 27 27 28 29 30 3 32 33 5 37 37 38 38 39 4 46 46 48 49 50 52 6 7 8 9 q w e

More information

1 目 錄 1. 簡 介... 2 2. 一 般 甄 試 程 序... 2 3. 第 一 階 段 的 準 備... 5 4. 第 二 階 段 的 準 備... 9 5. 每 間 學 校 的 面 試 方 式... 11 6. 各 程 序 我 的 做 法 心 得 及 筆 記... 13 7. 結 論..

1 目 錄 1. 簡 介... 2 2. 一 般 甄 試 程 序... 2 3. 第 一 階 段 的 準 備... 5 4. 第 二 階 段 的 準 備... 9 5. 每 間 學 校 的 面 試 方 式... 11 6. 各 程 序 我 的 做 法 心 得 及 筆 記... 13 7. 結 論.. 如 何 準 備 研 究 所 甄 試 劉 富 翃 1 目 錄 1. 簡 介... 2 2. 一 般 甄 試 程 序... 2 3. 第 一 階 段 的 準 備... 5 4. 第 二 階 段 的 準 備... 9 5. 每 間 學 校 的 面 試 方 式... 11 6. 各 程 序 我 的 做 法 心 得 及 筆 記... 13 7. 結 論... 20 8. 附 錄 8.1 推 甄 書 面 資 料...

More information

92 (When) (Where) (What) (Productivity) (Efficiency) () (2) (3) (4) (5) (6) (7) em-plant( SiMPLE++) Scheduling When Where Productivity Efficiency [5]

92 (When) (Where) (What) (Productivity) (Efficiency) () (2) (3) (4) (5) (6) (7) em-plant( SiMPLE++) Scheduling When Where Productivity Efficiency [5] DYNAMIC SCHEDULING IN TWO-MACHINE FLOW-SHOP WITH RECIRCULATION em-plant( SiMPLE++) Jen-Shiang Chen, Jar-Her Kao, Chun-Chieh Chen, Po-Cheng Liu, and Wen-Pin Lin Department of Industrial Engineering and

More information

untitled

untitled 51testing www.51testing.com UML Java Unified Modeling Language UML 1 UML 2 UML UML UML UML UML UML use case Java 1 2 3 4( 5 6 7 UNIX Windows OS/2 ( GUI ) 8 51testing www.51testing.com use caseactor ()

More information

第三节 软件测试的过程与策略

第三节 软件测试的过程与策略 ...1...4...9...17...25...29...34...40...46...55...65...73 1 2 3 4 5 6 7 8 9 10 11 1 12 13 1 ABCD 2 A B C D 3 ABCD 4 A1/2 B1/3 C1/4 D2/3 5 % A20 B30 C40 D50 6 A B C D 7 A B C D / 8 A B C D 9 A B C D 10

More information

Microsoft PowerPoint - L17_Inheritance_v4.pptx

Microsoft PowerPoint - L17_Inheritance_v4.pptx C++ Programming Lecture 17 Wei Liu ( 刘 威 ) Dept. of Electronics and Information Eng. Huazhong University of Science and Technology May. 2015 Lecture 17 Chapter 20. Object-Oriented Programming: Inheritance

More information

6-1 Table Column Data Type Row Record 1. DBMS 2. DBMS MySQL Microsoft Access SQL Server Oracle 3. ODBC SQL 1. Structured Query Language 2. IBM

6-1 Table Column Data Type Row Record 1. DBMS 2. DBMS MySQL Microsoft Access SQL Server Oracle 3. ODBC SQL 1. Structured Query Language 2. IBM CHAPTER 6 SQL SQL SQL 6-1 Table Column Data Type Row Record 1. DBMS 2. DBMS MySQL Microsoft Access SQL Server Oracle 3. ODBC SQL 1. Structured Query Language 2. IBM 3. 1986 10 ANSI SQL ANSI X3. 135-1986

More information

提纲 1 2 OS Examples for 3

提纲 1 2 OS Examples for 3 第 4 章 Threads2( 线程 2) 中国科学技术大学计算机学院 October 28, 2009 提纲 1 2 OS Examples for 3 Outline 1 2 OS Examples for 3 Windows XP Threads I An Windows XP application runs as a seperate process, and each process may

More information

概述

概述 OPC Version 1.8 build 0925 KOCRDK Knight OPC Client Rapid Development Toolkits Knight Workgroup, eehoo Technology 2002-9 OPC 1...4 2 API...5 2.1...5 2.2...5 2.2.1 KOC_Init...5 2.2.2 KOC_Uninit...5 2.3...5

More information

数据结构与算法 - Python基础

数据结构与算法 - 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

OSWorkflow Documentation

OSWorkflow Documentation OSWorkflow Documentation Update Time: 05/09/15 OSWorkflow Java workflow engine API 理 flow 行 XML 來 流 Database UI 不 流 GUI Designer end user 行 JSP+Servlet 行 OSWorkflow 2.8 說 2.7 2.7 了 OSWorkflow library library

More information

KillTest 质量更高 服务更好 学习资料 半年免费更新服务

KillTest 质量更高 服务更好 学习资料   半年免费更新服务 KillTest 质量更高 服务更好 学习资料 http://www.killtest.cn 半年免费更新服务 Exam : 70-536Chinese(C++) Title : TS:MS.NET Framework 2.0-Application Develop Foundation Version : DEMO 1 / 10 1. Exception A. Data B. Message C.

More information

Simulator By SunLingxi 2003

Simulator By SunLingxi 2003 Simulator By SunLingxi sunlingxi@sina.com 2003 windows 2000 Tornado ping ping 1. Tornado Full Simulator...3 2....3 3. ping...6 4. Tornado Simulator BSP...6 5. VxWorks simpc...7 6. simulator...7 7. simulator

More information

EK-STM32F

EK-STM32F STMEVKIT-STM32F10xx8 软 件 开 发 入 门 指 南 目 录 1 EWARM 安 装... 1 1.1 第 一 步 : 在 线 注 册... 1 1.2 第 二 步 : 下 载 软 件... 2 1.3 第 三 步 : 安 装 EWARM... 3 2 基 于 STMEVKIT-STM32F10xx8 的 示 例 代 码 运 行... 6 2.1 GPIO Demo... 6 2.2

More information

Chapter 9: Objects and Classes

Chapter 9: Objects and Classes Fortran Algol Pascal Modula-2 BCPL C Simula SmallTalk C++ Ada Java C# C Fortran 5.1 message A B 5.2 1 class Vehicle subclass Car object mycar public class Vehicle extends Object{ public int WheelNum

More information

PIC_SERVER (11) SMTP ( ) ( ) PIC_SERVER (10) SMTP PIC_SERVER (event driven) PIC_SERVER SMTP 1. E-

PIC_SERVER (11) SMTP  ( ) ( ) PIC_SERVER (10) SMTP  PIC_SERVER (event driven)  PIC_SERVER SMTP  1.  E- (2005-02-01) (2005-04-28) PIC_SERVER (10) SMTP E-mail PIC_SERVER (event driven) E-mail PIC_SERVER SMTP E-mail 1. E-mail E-mail 1 (1) (2) (3) (4) 1 1. 2 E-mail A E-mail B E-mail SMTP(Simple Mail Transfer

More information

Microsoft Word - CPE考生使用手冊160524.docx

Microsoft Word - CPE考生使用手冊160524.docx 大 學 程 式 能 力 檢 定 (CPE) 考 生 使 用 手 冊 2016 年 5 月 24 日 這 份 手 冊 提 供 給 參 加 CPE 檢 定 考 試 的 考 生 內 容 包 含 考 試 環 境 的 使 用, 以 及 解 題 時 所 使 用 I/O 的 基 本 知 識 1. 如 欲 報 名 參 加 CPE 考 試, 請 先 於 CPE 網 站 完 成 帳 號 註 冊, 然 後 再 報 名 該

More information

ebook8-30

ebook8-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 information

_汪_文前新ok[3.1].doc

_汪_文前新ok[3.1].doc 普 通 高 校 本 科 计 算 机 专 业 特 色 教 材 精 选 四 川 大 学 计 算 机 学 院 国 家 示 范 性 软 件 学 院 精 品 课 程 基 金 青 年 基 金 资 助 项 目 C 语 言 程 序 设 计 (C99 版 ) 陈 良 银 游 洪 跃 李 旭 伟 主 编 李 志 蜀 唐 宁 九 李 涛 主 审 清 华 大 学 出 版 社 北 京 i 内 容 简 介 本 教 材 面 向

More information

2013 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 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 information

C++ 程式設計

C++ 程式設計 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