SlideShare uma empresa Scribd logo
1 de 31
Baixar para ler offline
Programming
Languages
Have a vision of computer language evolution.
Distinguish between machine, assembly, and high-level
languages.
Understand the process of creating and running a program.
After reading this chapter, the reader should
be able to:
OBJECTIVES
Distinguish between the different categories of languages:
procedural, object-oriented, functional, declarative, and special.
Become familiar with elements of the procedural language C.
EVOLUTION
Evolution of computer languages
00000000 00000100 0000000000000000
01011110 00001100110000100000000000000010
11101111 000101100000000000000101
11101111 10011110 0000000000001011
11111000 10101101 11011111 0000000000010010
0110001011011111 0000000000010101
11101111 00000010 11111011 0000000000010111
11110100 1010110111011111 0000000000011110
0000001110100010 11011111 0000000000100001
11101111 00000010 11111011 0000000000100100
01111110 11110100 10101101
11111000 10101110110001010000000000101011
0000011010100010 11111011 0000000000110001
11101111 00000010 11111011 0000000000110100
00000100 0000000000111101
00000100 0000000000111101
Program in machine language
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
The only language understood by
a computer is machine language.
Note:
Entry main, ^m<r2>
subl2 #12,sp
jsb C$MAIN_ARGS
movab $CHAR_STRING_CON
pushal -8(fp)
pushal (r2)
calls #2,read
pushal -12(fp)
pushal 3(r2)
calls #2,read
mull3 -8(fp),-12(fp),-
pushal 6(r2)
calls #2,print
clrl r0
ret
Program in symbolic language
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* This program reads two integer numbers from the keyboard and prints their
product. */
#include <iostream.h>
int main (void)
{
// Local Declarations
int number1;
int number2;
int result;
// Statements
cin >> number1;
cin >> number2;
result = number1 * number2;
cout << result;
return 0;
}
// main
Program 9.3 Program in C++ language
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
BUILDING
A
PROGRAM
Building a Program
PROGRAM
EXECUTION
Program Execution
CATEGORIES
OF
LANGUAGES
Categories of Languages
Function in a functional Language
Common tags
Meaning
----------------------
document
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)
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>
<HTML>
<HEAD>
<TITLE> Sample Document </TITLE>
</HEAD>
<BODY>
This is the picture of a book:
<IMG SRC="Pictures/book1.gif" ALIGN=MIDDLE>
</BODY>
</HTML>
HTML Program
A PROCEDURAL
LANGUAGE:
C
Figure 9-7
Variables
Arithmetic operators
Example
----------------------
3 + 5
2 - 4
Num * 5
Sum / Count
Count % 4
-----------------------
Count ++
Count --
Operator
----------------
+
-
*
/
%
----------
++
--
Definition
----------------
Addition
Subtraction
Multiplication
Division (quotient)
Division (remainder)
-----------------------
Increment
Decrement
Relational operators
Example
----------------------
Num1 < 5
Num1 <= 5
Num2 > 3
Num2 >= 3
Num1 == Num2
Num1 != Num2
Operator
----------------
<
<=
>
>=
==
!=
Definition
----------------
Less than
Less than or equal to
Greater than
Greater than or equal to
Equal to
Not equal to
Logical operators
Example
----------------------
! ( Num1 < Num2 )
(Num1 < 5 ) && (Num2 > 10 )
(Num1 < 5 ) || (Num2 > 10 )
Operator
----------------
!
&&
||
Definition
----------------
NOT
AND
OR
Assignment operators
Meaning
----------------------
Store 5 in Num
Num = Num + 5
Num = Num - 5
Num = Num * 5
Num = Num / 5
Num = Num % 5
Operator
----------------
==
+=
-=
*=
/=
%=
Example
----------------
Num = 5
Num += 5
Num -= 5
Num *= 5
Num /= 5
Num %= 5
Statements
Side effect of a function
Function declaration
if-else statement
switch statement
while loop
for loop
do-while loop

Mais conteúdo relacionado

Mais procurados

High level and Low level Language
High level and Low level Language High level and Low level Language
High level and Low level Language adnan usmani
 
introduction to programming languages
introduction to programming languagesintroduction to programming languages
introduction to programming languagesNaqashAhmad14
 
Basic programming concepts
Basic programming conceptsBasic programming concepts
Basic programming conceptssalmankhan570
 
Compiler vs Interpreter-Compiler design ppt.
Compiler vs Interpreter-Compiler design ppt.Compiler vs Interpreter-Compiler design ppt.
Compiler vs Interpreter-Compiler design ppt.Md Hossen
 
Computer Language Translator
Computer Language TranslatorComputer Language Translator
Computer Language TranslatorRanjeet Kumar
 
pseudocode and Flowchart
pseudocode and Flowchartpseudocode and Flowchart
pseudocode and FlowchartALI RAZA
 
Introduction to Computer Programming
Introduction to Computer ProgrammingIntroduction to Computer Programming
Introduction to Computer ProgrammingProf. Erwin Globio
 
Microsoft Office Word Introduction Complete
Microsoft Office Word  Introduction CompleteMicrosoft Office Word  Introduction Complete
Microsoft Office Word Introduction CompleteRaj vardhan
 
Programming languages
Programming languagesProgramming languages
Programming languagesvito_carleone
 
Introduction to Programming Languages
Introduction to Programming LanguagesIntroduction to Programming Languages
Introduction to Programming Languageseducationfront
 
SPL 2 | Algorithms, Pseudo-code, and Flowchart
SPL 2 | Algorithms, Pseudo-code, and FlowchartSPL 2 | Algorithms, Pseudo-code, and Flowchart
SPL 2 | Algorithms, Pseudo-code, and FlowchartMohammad Imam Hossain
 

Mais procurados (20)

Looping in C
Looping in CLooping in C
Looping in C
 
High level and Low level Language
High level and Low level Language High level and Low level Language
High level and Low level Language
 
COMPUTER PROGRAMMING
COMPUTER PROGRAMMINGCOMPUTER PROGRAMMING
COMPUTER PROGRAMMING
 
Introduction to c programming
Introduction to c programmingIntroduction to c programming
Introduction to c programming
 
introduction to programming languages
introduction to programming languagesintroduction to programming languages
introduction to programming languages
 
Basic programming concepts
Basic programming conceptsBasic programming concepts
Basic programming concepts
 
Compiler vs Interpreter-Compiler design ppt.
Compiler vs Interpreter-Compiler design ppt.Compiler vs Interpreter-Compiler design ppt.
Compiler vs Interpreter-Compiler design ppt.
 
Computer Language Translator
Computer Language TranslatorComputer Language Translator
Computer Language Translator
 
pseudocode and Flowchart
pseudocode and Flowchartpseudocode and Flowchart
pseudocode and Flowchart
 
Evolution and History of Programming Languages - Software/Hardware/System
Evolution and History of Programming Languages - Software/Hardware/SystemEvolution and History of Programming Languages - Software/Hardware/System
Evolution and History of Programming Languages - Software/Hardware/System
 
Chapter 5
Chapter 5Chapter 5
Chapter 5
 
Computer languages 11
Computer languages 11Computer languages 11
Computer languages 11
 
Elements of programming
Elements of programmingElements of programming
Elements of programming
 
Introduction to Computer Programming
Introduction to Computer ProgrammingIntroduction to Computer Programming
Introduction to Computer Programming
 
Microsoft Office Word Introduction Complete
Microsoft Office Word  Introduction CompleteMicrosoft Office Word  Introduction Complete
Microsoft Office Word Introduction Complete
 
Programming
ProgrammingProgramming
Programming
 
Programming languages
Programming languagesProgramming languages
Programming languages
 
Introduction to Programming Languages
Introduction to Programming LanguagesIntroduction to Programming Languages
Introduction to Programming Languages
 
Function C++
Function C++ Function C++
Function C++
 
SPL 2 | Algorithms, Pseudo-code, and Flowchart
SPL 2 | Algorithms, Pseudo-code, and FlowchartSPL 2 | Algorithms, Pseudo-code, and Flowchart
SPL 2 | Algorithms, Pseudo-code, and Flowchart
 

Semelhante a Programming Language.ppt

Essential html tweaks for accessible themes
Essential html tweaks for accessible themesEssential html tweaks for accessible themes
Essential html tweaks for accessible themesMartin Stehle
 
Assignment Content1- Top of FormImagineyou have been asked to work at.docx
Assignment Content1- Top of FormImagineyou have been asked to work at.docxAssignment Content1- Top of FormImagineyou have been asked to work at.docx
Assignment Content1- Top of FormImagineyou have been asked to work at.docxnoel23456789
 
Chapter 1 - Basic concepts of programming.pdf
Chapter 1 - Basic concepts of programming.pdfChapter 1 - Basic concepts of programming.pdf
Chapter 1 - Basic concepts of programming.pdfKirubelWondwoson1
 
La 5 Programming1
La 5   Programming1La 5   Programming1
La 5 Programming1Cma Mohd
 
Introduction to domino_global_workbench_8.5
Introduction to domino_global_workbench_8.5Introduction to domino_global_workbench_8.5
Introduction to domino_global_workbench_8.5hepeiwei
 
Successfully Implement Responsive Design Behavior with Adobe Experience Manager
Successfully Implement Responsive Design Behavior with Adobe Experience ManagerSuccessfully Implement Responsive Design Behavior with Adobe Experience Manager
Successfully Implement Responsive Design Behavior with Adobe Experience ManagerPerficient, Inc.
 
C:\Users\User\Desktop\Eclipse Infocenter
C:\Users\User\Desktop\Eclipse InfocenterC:\Users\User\Desktop\Eclipse Infocenter
C:\Users\User\Desktop\Eclipse InfocenterSuite Solutions
 
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvvLecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvvZahouAmel1
 
LA5_PL Approach
LA5_PL ApproachLA5_PL Approach
LA5_PL ApproachCma Mohd
 
LA5_Generation of Programming Languages
LA5_Generation of Programming LanguagesLA5_Generation of Programming Languages
LA5_Generation of Programming LanguagesCma Mohd
 
What should or not be programmed on the web
What should or not be programmed on the  webWhat should or not be programmed on the  web
What should or not be programmed on the webMohammad Kamrul Hasan
 
Software development slides
Software development slidesSoftware development slides
Software development slidesiarthur
 
PowerShell Zero To Hero Workshop!
PowerShell Zero To Hero Workshop!PowerShell Zero To Hero Workshop!
PowerShell Zero To Hero Workshop!Daisy Stevens
 
Intro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & ClassesIntro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & ClassesBlue Elephant Consulting
 
Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++Blue Elephant Consulting
 

Semelhante a Programming Language.ppt (20)

Chapter 1
Chapter 1Chapter 1
Chapter 1
 
Essential html tweaks for accessible themes
Essential html tweaks for accessible themesEssential html tweaks for accessible themes
Essential html tweaks for accessible themes
 
Assignment Content1- Top of FormImagineyou have been asked to work at.docx
Assignment Content1- Top of FormImagineyou have been asked to work at.docxAssignment Content1- Top of FormImagineyou have been asked to work at.docx
Assignment Content1- Top of FormImagineyou have been asked to work at.docx
 
Chapter 4 computer language
Chapter 4 computer languageChapter 4 computer language
Chapter 4 computer language
 
Chapter 1 - Basic concepts of programming.pdf
Chapter 1 - Basic concepts of programming.pdfChapter 1 - Basic concepts of programming.pdf
Chapter 1 - Basic concepts of programming.pdf
 
Chapter 1
Chapter 1Chapter 1
Chapter 1
 
La 5 Programming1
La 5   Programming1La 5   Programming1
La 5 Programming1
 
Introduction to domino_global_workbench_8.5
Introduction to domino_global_workbench_8.5Introduction to domino_global_workbench_8.5
Introduction to domino_global_workbench_8.5
 
Successfully Implement Responsive Design Behavior with Adobe Experience Manager
Successfully Implement Responsive Design Behavior with Adobe Experience ManagerSuccessfully Implement Responsive Design Behavior with Adobe Experience Manager
Successfully Implement Responsive Design Behavior with Adobe Experience Manager
 
Chapter no 1
Chapter no 1Chapter no 1
Chapter no 1
 
C:\Users\User\Desktop\Eclipse Infocenter
C:\Users\User\Desktop\Eclipse InfocenterC:\Users\User\Desktop\Eclipse Infocenter
C:\Users\User\Desktop\Eclipse Infocenter
 
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvvLecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
 
LA5_PL Approach
LA5_PL ApproachLA5_PL Approach
LA5_PL Approach
 
LA5_Generation of Programming Languages
LA5_Generation of Programming LanguagesLA5_Generation of Programming Languages
LA5_Generation of Programming Languages
 
What should or not be programmed on the web
What should or not be programmed on the  webWhat should or not be programmed on the  web
What should or not be programmed on the web
 
Software development slides
Software development slidesSoftware development slides
Software development slides
 
PowerShell Zero To Hero Workshop!
PowerShell Zero To Hero Workshop!PowerShell Zero To Hero Workshop!
PowerShell Zero To Hero Workshop!
 
Sd Revision
Sd RevisionSd Revision
Sd Revision
 
Intro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & ClassesIntro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & Classes
 
Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++
 

Mais de Lovely Professional University

The HyperText Markup Language or HTML is the standard markup language
The HyperText Markup Language or HTML is the standard markup languageThe HyperText Markup Language or HTML is the standard markup language
The HyperText Markup Language or HTML is the standard markup languageLovely Professional University
 
Reasons for lower literacy among girls in himachal pradesh
Reasons for lower literacy among girls in himachal pradeshReasons for lower literacy among girls in himachal pradesh
Reasons for lower literacy among girls in himachal pradeshLovely Professional University
 
Evaluation of Data Mining Techniques for Predicting Student’s Performance
Evaluation of Data Mining Techniques for Predicting Student’s PerformanceEvaluation of Data Mining Techniques for Predicting Student’s Performance
Evaluation of Data Mining Techniques for Predicting Student’s PerformanceLovely Professional University
 

Mais de Lovely Professional University (20)

The HyperText Markup Language or HTML is the standard markup language
The HyperText Markup Language or HTML is the standard markup languageThe HyperText Markup Language or HTML is the standard markup language
The HyperText Markup Language or HTML is the standard markup language
 
Working with JSON
Working with JSONWorking with JSON
Working with JSON
 
Yargs Module
Yargs ModuleYargs Module
Yargs Module
 
NODEMON Module
NODEMON ModuleNODEMON Module
NODEMON Module
 
Getting Input from User
Getting Input from UserGetting Input from User
Getting Input from User
 
fs Module.pptx
fs Module.pptxfs Module.pptx
fs Module.pptx
 
Transaction Processing in DBMS.pptx
Transaction Processing in DBMS.pptxTransaction Processing in DBMS.pptx
Transaction Processing in DBMS.pptx
 
web_server_browser.ppt
web_server_browser.pptweb_server_browser.ppt
web_server_browser.ppt
 
Web Server.pptx
Web Server.pptxWeb Server.pptx
Web Server.pptx
 
Number System.pptx
Number System.pptxNumber System.pptx
Number System.pptx
 
Applications of Computer Science in Pharmacy-1.pptx
Applications of Computer Science in Pharmacy-1.pptxApplications of Computer Science in Pharmacy-1.pptx
Applications of Computer Science in Pharmacy-1.pptx
 
Setting up github and ssh keys.ppt
Setting up github and ssh keys.pptSetting up github and ssh keys.ppt
Setting up github and ssh keys.ppt
 
Adding a New Feature and Deploying.ppt
Adding a New Feature and Deploying.pptAdding a New Feature and Deploying.ppt
Adding a New Feature and Deploying.ppt
 
Requiring your own files.pptx
Requiring your own files.pptxRequiring your own files.pptx
Requiring your own files.pptx
 
Unit-2 Getting Input from User.pptx
Unit-2 Getting Input from User.pptxUnit-2 Getting Input from User.pptx
Unit-2 Getting Input from User.pptx
 
Yargs Module.pptx
Yargs Module.pptxYargs Module.pptx
Yargs Module.pptx
 
Working with JSON.pptx
Working with JSON.pptxWorking with JSON.pptx
Working with JSON.pptx
 
Restarting app with Nodemon.pptx
Restarting app with Nodemon.pptxRestarting app with Nodemon.pptx
Restarting app with Nodemon.pptx
 
Reasons for lower literacy among girls in himachal pradesh
Reasons for lower literacy among girls in himachal pradeshReasons for lower literacy among girls in himachal pradesh
Reasons for lower literacy among girls in himachal pradesh
 
Evaluation of Data Mining Techniques for Predicting Student’s Performance
Evaluation of Data Mining Techniques for Predicting Student’s PerformanceEvaluation of Data Mining Techniques for Predicting Student’s Performance
Evaluation of Data Mining Techniques for Predicting Student’s Performance
 

Último

Guardians and Glitches: Navigating the Duality of Gen AI in AppSec
Guardians and Glitches: Navigating the Duality of Gen AI in AppSecGuardians and Glitches: Navigating the Duality of Gen AI in AppSec
Guardians and Glitches: Navigating the Duality of Gen AI in AppSecTrupti Shiralkar, CISSP
 
Graphics Primitives and CG Display Devices
Graphics Primitives and CG Display DevicesGraphics Primitives and CG Display Devices
Graphics Primitives and CG Display DevicesDIPIKA83
 
How to Write a Good Scientific Paper.pdf
How to Write a Good Scientific Paper.pdfHow to Write a Good Scientific Paper.pdf
How to Write a Good Scientific Paper.pdfRedhwan Qasem Shaddad
 
Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...
Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...
Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...Amil baba
 
Engineering Mechanics Chapter 5 Equilibrium of a Rigid Body
Engineering Mechanics  Chapter 5  Equilibrium of a Rigid BodyEngineering Mechanics  Chapter 5  Equilibrium of a Rigid Body
Engineering Mechanics Chapter 5 Equilibrium of a Rigid BodyAhmadHajasad2
 
Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...
Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...
Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...Sean Meyn
 
Clutches and brkesSelect any 3 position random motion out of real world and d...
Clutches and brkesSelect any 3 position random motion out of real world and d...Clutches and brkesSelect any 3 position random motion out of real world and d...
Clutches and brkesSelect any 3 position random motion out of real world and d...sahb78428
 
Technology Features of Apollo HDD Machine, Its Technical Specification with C...
Technology Features of Apollo HDD Machine, Its Technical Specification with C...Technology Features of Apollo HDD Machine, Its Technical Specification with C...
Technology Features of Apollo HDD Machine, Its Technical Specification with C...Apollo Techno Industries Pvt Ltd
 
Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...
Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...
Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...amrabdallah9
 
SUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docx
SUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docxSUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docx
SUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docxNaveenVerma126
 
The relationship between iot and communication technology
The relationship between iot and communication technologyThe relationship between iot and communication technology
The relationship between iot and communication technologyabdulkadirmukarram03
 
Dev.bg DevOps March 2024 Monitoring & Logging
Dev.bg DevOps March 2024 Monitoring & LoggingDev.bg DevOps March 2024 Monitoring & Logging
Dev.bg DevOps March 2024 Monitoring & LoggingMarian Marinov
 
Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...
Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...
Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...Amil baba
 
Lecture 1: Basics of trigonometry (surveying)
Lecture 1: Basics of trigonometry (surveying)Lecture 1: Basics of trigonometry (surveying)
Lecture 1: Basics of trigonometry (surveying)Bahzad5
 
دليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide Laboratory
دليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide Laboratoryدليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide Laboratory
دليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide LaboratoryBahzad5
 

Último (20)

Guardians and Glitches: Navigating the Duality of Gen AI in AppSec
Guardians and Glitches: Navigating the Duality of Gen AI in AppSecGuardians and Glitches: Navigating the Duality of Gen AI in AppSec
Guardians and Glitches: Navigating the Duality of Gen AI in AppSec
 
Graphics Primitives and CG Display Devices
Graphics Primitives and CG Display DevicesGraphics Primitives and CG Display Devices
Graphics Primitives and CG Display Devices
 
How to Write a Good Scientific Paper.pdf
How to Write a Good Scientific Paper.pdfHow to Write a Good Scientific Paper.pdf
How to Write a Good Scientific Paper.pdf
 
Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...
Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...
Popular-NO1 Kala Jadu Expert Specialist In Germany Kala Jadu Expert Specialis...
 
Engineering Mechanics Chapter 5 Equilibrium of a Rigid Body
Engineering Mechanics  Chapter 5  Equilibrium of a Rigid BodyEngineering Mechanics  Chapter 5  Equilibrium of a Rigid Body
Engineering Mechanics Chapter 5 Equilibrium of a Rigid Body
 
Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...
Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...
Quasi-Stochastic Approximation: Algorithm Design Principles with Applications...
 
Lecture 4 .pdf
Lecture 4                              .pdfLecture 4                              .pdf
Lecture 4 .pdf
 
Clutches and brkesSelect any 3 position random motion out of real world and d...
Clutches and brkesSelect any 3 position random motion out of real world and d...Clutches and brkesSelect any 3 position random motion out of real world and d...
Clutches and brkesSelect any 3 position random motion out of real world and d...
 
Technology Features of Apollo HDD Machine, Its Technical Specification with C...
Technology Features of Apollo HDD Machine, Its Technical Specification with C...Technology Features of Apollo HDD Machine, Its Technical Specification with C...
Technology Features of Apollo HDD Machine, Its Technical Specification with C...
 
計劃趕得上變化
計劃趕得上變化計劃趕得上變化
計劃趕得上變化
 
Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...
Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...
Strategies of Urban Morphologyfor Improving Outdoor Thermal Comfort and Susta...
 
Présentation IIRB 2024 Chloe Dufrane.pdf
Présentation IIRB 2024 Chloe Dufrane.pdfPrésentation IIRB 2024 Chloe Dufrane.pdf
Présentation IIRB 2024 Chloe Dufrane.pdf
 
SUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docx
SUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docxSUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docx
SUMMER TRAINING REPORT ON BUILDING CONSTRUCTION.docx
 
Litature Review: Research Paper work for Engineering
Litature Review: Research Paper work for EngineeringLitature Review: Research Paper work for Engineering
Litature Review: Research Paper work for Engineering
 
The relationship between iot and communication technology
The relationship between iot and communication technologyThe relationship between iot and communication technology
The relationship between iot and communication technology
 
Dev.bg DevOps March 2024 Monitoring & Logging
Dev.bg DevOps March 2024 Monitoring & LoggingDev.bg DevOps March 2024 Monitoring & Logging
Dev.bg DevOps March 2024 Monitoring & Logging
 
Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...
Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...
Best-NO1 Best Rohani Amil In Lahore Kala Ilam In Lahore Kala Jadu Amil In Lah...
 
Lecture 1: Basics of trigonometry (surveying)
Lecture 1: Basics of trigonometry (surveying)Lecture 1: Basics of trigonometry (surveying)
Lecture 1: Basics of trigonometry (surveying)
 
دليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide Laboratory
دليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide Laboratoryدليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide Laboratory
دليل تجارب الاسفلت المختبرية - Asphalt Experiments Guide Laboratory
 
Lecture 2 .pptx
Lecture 2                            .pptxLecture 2                            .pptx
Lecture 2 .pptx
 

Programming Language.ppt

  • 2. Have a vision of computer language evolution. Distinguish between machine, assembly, and high-level languages. Understand the process of creating and running a program. After reading this chapter, the reader should be able to: OBJECTIVES Distinguish between the different categories of languages: procedural, object-oriented, functional, declarative, and special. Become familiar with elements of the procedural language C.
  • 5. 00000000 00000100 0000000000000000 01011110 00001100110000100000000000000010 11101111 000101100000000000000101 11101111 10011110 0000000000001011 11111000 10101101 11011111 0000000000010010 0110001011011111 0000000000010101 11101111 00000010 11111011 0000000000010111 11110100 1010110111011111 0000000000011110 0000001110100010 11011111 0000000000100001 11101111 00000010 11111011 0000000000100100 01111110 11110100 10101101 11111000 10101110110001010000000000101011 0000011010100010 11111011 0000000000110001 11101111 00000010 11111011 0000000000110100 00000100 0000000000111101 00000100 0000000000111101 Program in machine language 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
  • 6. The only language understood by a computer is machine language. Note:
  • 7. Entry main, ^m<r2> subl2 #12,sp jsb C$MAIN_ARGS movab $CHAR_STRING_CON pushal -8(fp) pushal (r2) calls #2,read pushal -12(fp) pushal 3(r2) calls #2,read mull3 -8(fp),-12(fp),- pushal 6(r2) calls #2,print clrl r0 ret Program in symbolic language 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
  • 8. /* This program reads two integer numbers from the keyboard and prints their product. */ #include <iostream.h> int main (void) { // Local Declarations int number1; int number2; int result; // Statements cin >> number1; cin >> number2; result = number1 * number2; cout << result; return 0; } // main Program 9.3 Program in C++ language 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
  • 15. Function in a functional Language
  • 16. Common tags Meaning ---------------------- document 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) 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>
  • 17. <HTML> <HEAD> <TITLE> Sample Document </TITLE> </HEAD> <BODY> This is the picture of a book: <IMG SRC="Pictures/book1.gif" ALIGN=MIDDLE> </BODY> </HTML> HTML Program
  • 20. Arithmetic operators Example ---------------------- 3 + 5 2 - 4 Num * 5 Sum / Count Count % 4 ----------------------- Count ++ Count -- Operator ---------------- + - * / % ---------- ++ -- Definition ---------------- Addition Subtraction Multiplication Division (quotient) Division (remainder) ----------------------- Increment Decrement
  • 21. Relational operators Example ---------------------- Num1 < 5 Num1 <= 5 Num2 > 3 Num2 >= 3 Num1 == Num2 Num1 != Num2 Operator ---------------- < <= > >= == != Definition ---------------- Less than Less than or equal to Greater than Greater than or equal to Equal to Not equal to
  • 22. Logical operators Example ---------------------- ! ( Num1 < Num2 ) (Num1 < 5 ) && (Num2 > 10 ) (Num1 < 5 ) || (Num2 > 10 ) Operator ---------------- ! && || Definition ---------------- NOT AND OR
  • 23. Assignment operators Meaning ---------------------- Store 5 in Num Num = Num + 5 Num = Num - 5 Num = Num * 5 Num = Num / 5 Num = Num % 5 Operator ---------------- == += -= *= /= %= Example ---------------- Num = 5 Num += 5 Num -= 5 Num *= 5 Num /= 5 Num %= 5
  • 25. Side effect of a function