Add your company slogan 7 Programming Language LOGO
- Slides: 37
“ Add your company slogan ” บทท 7 Programming Language LOGO
ววฒนาการของภาษาคอมพ วเตอร 1 Machine Language 2 Symbolic Language 3 High-Level Language 4 Natural Language
Program in Machine Language โปรแกรม ทำการคณเลข 2 จำนวนแลวพมพผลลพธ 1 00000100 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 01011110 11111000 111011110100 00000011 11101111110 11111000 00000110 11101111 00001100 11101111 10101101 01100010 00000010 10101101 10100010 00000010 11110100 10101110 10100010 0000000000 11000010 000000010110 0000000101 10011110 0000001011 11011111 00000010010 11011111 00000010101 11111011 00000010111 11011111 00000011110 11011111 00000100001 11111011 00000100100 10101101 11000101 00000101011 11111011 00000110001 11111011 00000110100 0000000000111101 00000100 00000111101
Program in symbolic language โปรแกรม ทำการคณเลข 2 จำนวนแลวพมพผลลพธ 1 Entry main, ^m<r 2> 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 subl 2 #12, sp jsb C$MAIN_ARGS movab $CHAR_STRING_CON pushal calls mull 3 pushal calls clrl ret -8(fp) (r 2) #2, read -12(fp) 3(r 2) #2, read -8(fp), -12(fp), 6(r 2) #2, print r 0
Program in C++ Language โปรแกรม ทำการคณเลข 2 จำนวนแลวพมพผลลพธ 1 /* This program reads two integer numbers from the 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 keyboard and prints their product. */ #include <iostream. h> int main (void) { // Local Declarations int number 1; int number 2; int result; // Statements cin >> number 1; cin >> number 2; result = number 1 * number 2; cout << result; return 0; } // main
Program Execution
Categories of Languages
Function in a Functional Language
Extracting the Third Element of a List
Common Tags Beginning Tag --------<HTML> <HEAD> <BODY> <TITLE> <Hi> <B> <I> <U> <SUB> <SUP> <CENTER> <BR> <OL> <UL> <LI> <IMG> <A> Ending Tag --------</HTML> </HEAD> </BODY> </TITLE> </Hi> </B> </I> </U> </SUB> </SUP> </CENTER> </OL> </UL> </LI> </A> Meaning --------------document head document body document title different header levels boldface Italic underlined subscript superscript centered line break ordered list unordered list an item in the list an image an address (hyperlink)
HTML Program <HTML> <HEAD> <TITLE> Sample Document </TITLE> </HEAD> <BODY> This is the picture of a book: <IMG SRC="Pictures/book 1. gif" ALIGN=MIDDLE> </BODY> </HTML>
Arithmetic Operators Operator --------+ * / % -----++ -- Definition --------Addition Subtraction Multiplication Division (quotient) Division (remainder) -----------Increment Decrement Example -----------3 + 5 2 - 4 Num * 5 Sum / Count % 4 -----------Count ++ Count --
Relational Operators Operator --------< Definition --------Less than Example -----------Num 1 < 5 <= Less than or equal to Num 1 <= 5 > Greater than Num 2 > 3 >= Greater than or equal to Num 2 >= 3 == Equal to Num 1 == Num 2 != Not equal to Num 1 != Num 2
Logical Operators Operator --------! Definition --------NOT Example -----------! ( Num 1 < Num 2 ) && AND || OR (Num 1 < 5 ) && (Num 2 > 10 ) (Num 1 < 5 ) || (Num 2 > 10 )
Assignment Operators Operator --------== Example --------Num =5 Meaning -----------Store 5 in Num += 5 Num = Num + 5 -= Num -= 5 Num = Num - 5 *= Num *= 5 Num = Num * 5 /= Num /= 5 Num = Num / %= Num %= 5 5 Num = Num % 5
Statements
Side Effect of a Function
Function Declaration
IF-ELSE Statement
Switch Statement
WHILE Loop
FOR Loop
DO-WHILE Loop
Procedural Languages § Procedural Language เปนภาษาท Execute คำสงทละคำสงตามลำดบทเรยงไว การทำงานเปนไปแบบทละขนตอน (step by step) ตามอลกอรธมทกำหนดโดยมโครงสรางทงสามโครงสรางเป นตวกำหนด ภาษาทสำคญในกลม น ไดแก * FORTRAN (FORmula TRANslation) * COBOL (COmmon Business Oriented Language) * Pascal : 1971 by Niklaus Wirth in Zurich, Swiss. * C : 1970 by Dennis Ritchie at Bell Laboratory * Ada (Augusta Ada Byron) for Do. D
“ Add your company slogan ” LOGO
- Company name your slogan here
- Company slogan here
- Click to add titleclick to add subtitle
- Click to add subtitle
- Click to add titleclick to add subtitle
- Fd msw
- Logo pendahuluan
- C programming language logo
- Language
- [email protected]
- Introduction of amway
- Company slogan here
- Company slogan here
- Disney culture statement
- Walt disney conclusion
- What is hdl hardware description language
- Perbedaan linear programming dan integer programming
- Greedy vs dynamic programming
- What is system programming
- Integer programming vs linear programming
- Programing adalah
- Front loaded sentence examples
- Add to your faith virtue nkjv
- Greek word for kindness
- And to your faith add
- Add your title here
- Add your title here
- Add to your faith
- Insert your text here
- Add your title here
- Work in pairs discuss the following questions
- Add your title here
- Give us your hungry your tired your poor
- Linear programming case study examples
- Flair furniture company linear programming
- Qm for windows
- Buy it sell it love it slogan
- Sprite catchphrase