尊敬的 微信汇率:1円 ≈ 0.046166 元 支付宝汇率:1円 ≈ 0.046257元 [退出登录]
SlideShare a Scribd company logo
Introduction to Programming
Presented By:
Marina Gul
Course Objectives
 The aim is not to make you the expert of
computer programming but only the
basics of computer programming.
 To familiarize students with the use of
C++.
 To equip students with tools and
techniques to implement a given problem
programmatically
Why this Course?
Recommended Book
 Problem Solving with C++ 10th edition by
Walter Savitch- Pearson Prentice-Hall
 C++ Programming from Problem Analysis
to Program Design, 7th Edition, By, DS
Malik
 Programming in C++ by Dietel and Dietal
 Programming in C++ by Robert Laphore
 Lecture Handouts
IDEs used for this course
 You can use any of the IDEs given below;
but we will use Dev C++ in the classes
and Labs
 DEV C++
 Visual C++
 Turbo C++
Grading Criteria
Mid Term = 20%
Final Exam = 50%
Quizzes = 5%
CP & CB = 5%
Assignments = 10%
Project = 10%
Lecture No. 1-3
Introduction to C& C++
Topics to be Covered
 Computer Systems
 Programing & Problem Solving
 Introduction to C++
Computer Systems
Computer Systems
 Hardware: Physical devices
 Software: Instructions and computer
programs
Hardware
 Input : Keyboard, Mouse
 Central Processing Unit (CPU)
 Main Memory: Random Access Memory
(RAM)
 Output: Monitor, Printer
 Secondary Storage: Disk Drive
Main Components of a Computer
Memory Locations and Bytes
Software
 Instructions for the hardware.
 Actions to be performed
 A set of instructions is called a program.
 Driving force behind the computer
 Without a program – What is a computer?
▪ Collection of Useless Hardware
 2 purposes:
 Tell the computer what to do
 Tell other people what we want the computer to
do.
Programming Language
 Digital devices have two stable states,
zero and one
 A single digit (0 or 1) is called a bit, short
for binary digit. A byte is made up of 8
bits.
 Binary Language: Data and instructions
(numbers, characters, strings, etc.) are
encoded as binary numbers - a series of
bits, called byte.
Homework (1 Mark)
Task 1
 Search about Quantum computing and
make a 1 page summary in which you
have to write its working and how it makes
a difference from conventional computing?
 Deadline : 9-09-2022
Programming Languages
 Computers can not use human
languages, and programming in the
binary language of computers is a very
difficult, tedious process
 Therefore, most programs are written
using a programming language and are
converted to the binary language used
by the computer
 Three major categories of prog languages:
 Machine Language
 Assembly Language
 High level Language
Machine Language
 Natural language of a particular computer
 Primitive instructions built into every
computer
 The instructions are in the form of binary
code
 Any other types of languages must be
translated down to this level
 Example: 0110 1001 1010 1011
Assembly Languages
 English-like Abbreviations used for
operations ADD X Y Z
 Assembly languages were developed to
make programming easier
 The computer cannot understand
assembly language - a program called
assembler is used to convert assembly
language programs into machine code
High Level Languages
 English-like and easy to learn and
program
 Common mathematical notation
 Total Cost = Price + Tax;
 area = 5 * 5 * 3.1415;
 Java, Python,C, C++, FORTRAN,COBOL,
VISUAL BASIC, PASCAL
Compilers
 A compiler is a program that translates a
high-level language program, such as a
C++ program, into a machine-language
program that the computer can directly
understand and execute.
Programming and Problem-
Solving
What is Program and
Programming ?
 Program is a set of instructions, which
performs any particular task.
 Programming is a process of problem
solving. Different people use different
techniques to solve problems
Problem Solving
 The process of defining a problem, searching for
relevant information and resources about the
problem, and of discovering, designing, and
evaluating the solutions for further opportunities.
Includes:
 Finding an Answer to a Question
 Figuring out how to Perform a Task
 Figure out how to Make Things Work
 Not enough to know a particular programming
language… Must be able to problem solve…
Polya’s 4 Steps of Problem Solving
 Problem Solving Phase
 U – Understand the Problem
 D – Devise a Good Plan to Solve
 Implementation Phase
 I – Implement the Plan
 E – Evaluate the Solution
Example
 Determine how many times a name occurs
in a list of names:
Example
 Determine how many times a name occurs
in a list of names:
1. Get the list of names.
2. Get the name being checked.
3. Set a counter to zero.
4. Do the following for each name on the list: Compare the name on
the list to the name being checked, and if the names are the same,
then add one to the counter.
5. Announce that the answer is the number indicated by the counter.
 The instructions numbered 1 through 5 is
algorithm
Algorithm
 A sequence of precise instructions which
leads to a solution is called an algorithm.
 Some approximately equivalent words are
recipe, method, directions, procedure, and
routine.
Class Activity
 Write an algorithm to serve as how-to
instructions for given picture. Instructions
should be 10-20 steps in length. Assume
you are writing instructions who is
ROBOT.
Program Design
 To produce a program in a programming
language such as C++, the algorithm is
translated into the programming language.
Producing the final program from the
algorithm is called the implementation
phase.
Introduction to C++
History and Introduction to C++
 C++ is a programming language
 It was developed by Dennis Riche at Bell’s Lab in
1971.
 In C++, we can make new software or programs.
History and Introduction to C++
 Before C++, there were so many
languages which were being used by the
programmers like GW Basic, Pascal, and
Fortran etc. But after the birth of C++,
it becomes more famous than all other
languages. So many of the programmers
divorced the other languages and
happily married with C++.
Features of C Language
 C++ is considered as High level language.
 C++ is case sensitive language.
 C++ has compiler as a language translator.
 C++ is hybrid language (Combination of
structured as well as Object orientation
paradigm)
Homework (1 Mark)
Task 02
 Search and write briefly about Generation
of Programming languages.
Terminologies
 Computer Programming:
The process of developing and implementing various sets of instructions to
enable a computer to do a certain task is called Computer Programming.
 Computer Program:
A program is a set of step-by-step instructions that directs the computer
what to do and how to do.
 Computer Programmer:
The one who is expert in writing computer programs or developing the
software is called a computer programmer or developer.
 Programming Language:
A programming language is a formal constructed language designed to
communicate instructions to a machine, particularly a computer.
IDEs
 An integrated development environment is
a software application that provides
comprehensive facilities to computer
program
 An IDE normally consists of at least a
source code editor, build automation tools,
and a debugger.
Editor, Linker, Loader,
Compiler, Debugger
 IDE has editor, linker, compiler, loader, executer and
debugger.
 Editor: In editor we write the source code.
 Compiler: Converts the source code in to machine code.
 Linker: Linker links the object code with libraries.
 Loader: Loader loads program in to the memory.
 Executer: This unit executes the program.
 Debugger: This unit helps in removing the defect or
errors or logical errors.
Recap of the lecture
•Introduction to Computer
•What is Program ?
•History and Development of C-Language
•Features of C-Language
•Level and Generations of Programming Languages
•Terminologies
Recommended Readings
Chapter No. 1 of
Problem Solving with C++ 10th edition by
Walter Savitch- Pearson Prentice-Hall
&
C++ Programming from Problem Analysis to
Program Design written by DS Malik

More Related Content

Similar to Lecture 1-3.ppt

Comso c++
Comso c++Comso c++
Comso c++
Mi L
 
CS3251-_PIC
CS3251-_PICCS3251-_PIC
An introduction to programming
An introduction to programmingAn introduction to programming
An introduction to programming
rprajat007
 
Lesson 1
Lesson 1Lesson 1
C Unit 1 notes PREPARED BY MVB REDDY
C Unit 1 notes PREPARED BY MVB REDDYC Unit 1 notes PREPARED BY MVB REDDY
C Unit 1 notes PREPARED BY MVB REDDY
Rajeshkumar Reddy
 
Chapter 2.pptx
Chapter 2.pptxChapter 2.pptx
Chapter 2.pptx
TamiratDejene1
 
Programming in C
Programming in CProgramming in C
Programming in C
Rvishnupriya2
 
Programming in c
Programming in cProgramming in c
Programming in c
vishnu973656
 
C programme presentation
C programme presentationC programme presentation
C programme presentation
DharmaKumariBhandari
 
Savitch ch 01
Savitch ch 01Savitch ch 01
Savitch ch 01
Terry Yoast
 
Savitch ch 01
Savitch ch 01Savitch ch 01
Savitch ch 01
Terry Yoast
 
Programming in c
Programming in cProgramming in c
Programming in c
ankitjain851
 
C.pdf
C.pdfC.pdf
Introduction to c_language
Introduction to c_languageIntroduction to c_language
Introduction to c_language
Way2itech
 
Cmp2412 programming principles
Cmp2412 programming principlesCmp2412 programming principles
Cmp2412 programming principles
NIKANOR THOMAS
 
Cw1
Cw1Cw1
Intro. to prog. c++
Intro. to prog. c++Intro. to prog. c++
Intro. to prog. c++
KurdGul
 
BIS07 Application Development - I
BIS07 Application Development - IBIS07 Application Development - I
BIS07 Application Development - I
Prithwis Mukerjee
 
Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12
Sehrish Rafiq
 
Ppt 1
Ppt 1Ppt 1

Similar to Lecture 1-3.ppt (20)

Comso c++
Comso c++Comso c++
Comso c++
 
CS3251-_PIC
CS3251-_PICCS3251-_PIC
CS3251-_PIC
 
An introduction to programming
An introduction to programmingAn introduction to programming
An introduction to programming
 
Lesson 1
Lesson 1Lesson 1
Lesson 1
 
C Unit 1 notes PREPARED BY MVB REDDY
C Unit 1 notes PREPARED BY MVB REDDYC Unit 1 notes PREPARED BY MVB REDDY
C Unit 1 notes PREPARED BY MVB REDDY
 
Chapter 2.pptx
Chapter 2.pptxChapter 2.pptx
Chapter 2.pptx
 
Programming in C
Programming in CProgramming in C
Programming in C
 
Programming in c
Programming in cProgramming in c
Programming in c
 
C programme presentation
C programme presentationC programme presentation
C programme presentation
 
Savitch ch 01
Savitch ch 01Savitch ch 01
Savitch ch 01
 
Savitch ch 01
Savitch ch 01Savitch ch 01
Savitch ch 01
 
Programming in c
Programming in cProgramming in c
Programming in c
 
C.pdf
C.pdfC.pdf
C.pdf
 
Introduction to c_language
Introduction to c_languageIntroduction to c_language
Introduction to c_language
 
Cmp2412 programming principles
Cmp2412 programming principlesCmp2412 programming principles
Cmp2412 programming principles
 
Cw1
Cw1Cw1
Cw1
 
Intro. to prog. c++
Intro. to prog. c++Intro. to prog. c++
Intro. to prog. c++
 
BIS07 Application Development - I
BIS07 Application Development - IBIS07 Application Development - I
BIS07 Application Development - I
 
Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12
 
Ppt 1
Ppt 1Ppt 1
Ppt 1
 

Recently uploaded

A Quiz on Drug Abuse Awareness by Quizzito
A Quiz on Drug Abuse Awareness by QuizzitoA Quiz on Drug Abuse Awareness by Quizzito
A Quiz on Drug Abuse Awareness by Quizzito
Quizzito The Quiz Society of Gargi College
 
IoT (Internet of Things) introduction Notes.pdf
IoT (Internet of Things) introduction Notes.pdfIoT (Internet of Things) introduction Notes.pdf
IoT (Internet of Things) introduction Notes.pdf
roshanranjit222
 
220711130097 Tulip Samanta Concept of Information and Communication Technology
220711130097 Tulip Samanta Concept of Information and Communication Technology220711130097 Tulip Samanta Concept of Information and Communication Technology
220711130097 Tulip Samanta Concept of Information and Communication Technology
Kalna College
 
Interprofessional Education Platform Introduction.pdf
Interprofessional Education Platform Introduction.pdfInterprofessional Education Platform Introduction.pdf
Interprofessional Education Platform Introduction.pdf
Ben Aldrich
 
How to Create User Notification in Odoo 17
How to Create User Notification in Odoo 17How to Create User Notification in Odoo 17
How to Create User Notification in Odoo 17
Celine George
 
220711130088 Sumi Basak Virtual University EPC 3.pptx
220711130088 Sumi Basak Virtual University EPC 3.pptx220711130088 Sumi Basak Virtual University EPC 3.pptx
220711130088 Sumi Basak Virtual University EPC 3.pptx
Kalna College
 
The Science of Learning: implications for modern teaching
The Science of Learning: implications for modern teachingThe Science of Learning: implications for modern teaching
The Science of Learning: implications for modern teaching
Derek Wenmoth
 
Decolonizing Universal Design for Learning
Decolonizing Universal Design for LearningDecolonizing Universal Design for Learning
Decolonizing Universal Design for Learning
Frederic Fovet
 
What are the new features in the Fleet Odoo 17
What are the new features in the Fleet Odoo 17What are the new features in the Fleet Odoo 17
What are the new features in the Fleet Odoo 17
Celine George
 
Library news letter Kitengesa Uganda June 2024
Library news letter Kitengesa Uganda June 2024Library news letter Kitengesa Uganda June 2024
Library news letter Kitengesa Uganda June 2024
Friends of African Village Libraries
 
Creation or Update of a Mandatory Field is Not Set in Odoo 17
Creation or Update of a Mandatory Field is Not Set in Odoo 17Creation or Update of a Mandatory Field is Not Set in Odoo 17
Creation or Update of a Mandatory Field is Not Set in Odoo 17
Celine George
 
How to stay relevant as a cyber professional: Skills, trends and career paths...
How to stay relevant as a cyber professional: Skills, trends and career paths...How to stay relevant as a cyber professional: Skills, trends and career paths...
How to stay relevant as a cyber professional: Skills, trends and career paths...
Infosec
 
220711130083 SUBHASHREE RAKSHIT Internet resources for social science
220711130083 SUBHASHREE RAKSHIT  Internet resources for social science220711130083 SUBHASHREE RAKSHIT  Internet resources for social science
220711130083 SUBHASHREE RAKSHIT Internet resources for social science
Kalna College
 
Information and Communication Technology in Education
Information and Communication Technology in EducationInformation and Communication Technology in Education
Information and Communication Technology in Education
MJDuyan
 
Creativity for Innovation and Speechmaking
Creativity for Innovation and SpeechmakingCreativity for Innovation and Speechmaking
Creativity for Innovation and Speechmaking
MattVassar1
 
220711130095 Tanu Pandey message currency, communication speed & control EPC ...
220711130095 Tanu Pandey message currency, communication speed & control EPC ...220711130095 Tanu Pandey message currency, communication speed & control EPC ...
220711130095 Tanu Pandey message currency, communication speed & control EPC ...
Kalna College
 
BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...
BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...
BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...
Nguyen Thanh Tu Collection
 
nutrition in plants chapter 1 class 7...
nutrition in plants chapter 1 class 7...nutrition in plants chapter 1 class 7...
nutrition in plants chapter 1 class 7...
chaudharyreet2244
 
8+8+8 Rule Of Time Management For Better Productivity
8+8+8 Rule Of Time Management For Better Productivity8+8+8 Rule Of Time Management For Better Productivity
8+8+8 Rule Of Time Management For Better Productivity
RuchiRathor2
 
Diversity Quiz Finals by Quiz Club, IIT Kanpur
Diversity Quiz Finals by Quiz Club, IIT KanpurDiversity Quiz Finals by Quiz Club, IIT Kanpur
Diversity Quiz Finals by Quiz Club, IIT Kanpur
Quiz Club IIT Kanpur
 

Recently uploaded (20)

A Quiz on Drug Abuse Awareness by Quizzito
A Quiz on Drug Abuse Awareness by QuizzitoA Quiz on Drug Abuse Awareness by Quizzito
A Quiz on Drug Abuse Awareness by Quizzito
 
IoT (Internet of Things) introduction Notes.pdf
IoT (Internet of Things) introduction Notes.pdfIoT (Internet of Things) introduction Notes.pdf
IoT (Internet of Things) introduction Notes.pdf
 
220711130097 Tulip Samanta Concept of Information and Communication Technology
220711130097 Tulip Samanta Concept of Information and Communication Technology220711130097 Tulip Samanta Concept of Information and Communication Technology
220711130097 Tulip Samanta Concept of Information and Communication Technology
 
Interprofessional Education Platform Introduction.pdf
Interprofessional Education Platform Introduction.pdfInterprofessional Education Platform Introduction.pdf
Interprofessional Education Platform Introduction.pdf
 
How to Create User Notification in Odoo 17
How to Create User Notification in Odoo 17How to Create User Notification in Odoo 17
How to Create User Notification in Odoo 17
 
220711130088 Sumi Basak Virtual University EPC 3.pptx
220711130088 Sumi Basak Virtual University EPC 3.pptx220711130088 Sumi Basak Virtual University EPC 3.pptx
220711130088 Sumi Basak Virtual University EPC 3.pptx
 
The Science of Learning: implications for modern teaching
The Science of Learning: implications for modern teachingThe Science of Learning: implications for modern teaching
The Science of Learning: implications for modern teaching
 
Decolonizing Universal Design for Learning
Decolonizing Universal Design for LearningDecolonizing Universal Design for Learning
Decolonizing Universal Design for Learning
 
What are the new features in the Fleet Odoo 17
What are the new features in the Fleet Odoo 17What are the new features in the Fleet Odoo 17
What are the new features in the Fleet Odoo 17
 
Library news letter Kitengesa Uganda June 2024
Library news letter Kitengesa Uganda June 2024Library news letter Kitengesa Uganda June 2024
Library news letter Kitengesa Uganda June 2024
 
Creation or Update of a Mandatory Field is Not Set in Odoo 17
Creation or Update of a Mandatory Field is Not Set in Odoo 17Creation or Update of a Mandatory Field is Not Set in Odoo 17
Creation or Update of a Mandatory Field is Not Set in Odoo 17
 
How to stay relevant as a cyber professional: Skills, trends and career paths...
How to stay relevant as a cyber professional: Skills, trends and career paths...How to stay relevant as a cyber professional: Skills, trends and career paths...
How to stay relevant as a cyber professional: Skills, trends and career paths...
 
220711130083 SUBHASHREE RAKSHIT Internet resources for social science
220711130083 SUBHASHREE RAKSHIT  Internet resources for social science220711130083 SUBHASHREE RAKSHIT  Internet resources for social science
220711130083 SUBHASHREE RAKSHIT Internet resources for social science
 
Information and Communication Technology in Education
Information and Communication Technology in EducationInformation and Communication Technology in Education
Information and Communication Technology in Education
 
Creativity for Innovation and Speechmaking
Creativity for Innovation and SpeechmakingCreativity for Innovation and Speechmaking
Creativity for Innovation and Speechmaking
 
220711130095 Tanu Pandey message currency, communication speed & control EPC ...
220711130095 Tanu Pandey message currency, communication speed & control EPC ...220711130095 Tanu Pandey message currency, communication speed & control EPC ...
220711130095 Tanu Pandey message currency, communication speed & control EPC ...
 
BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...
BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...
BỘ BÀI TẬP TEST THEO UNIT - FORM 2025 - TIẾNG ANH 12 GLOBAL SUCCESS - KÌ 1 (B...
 
nutrition in plants chapter 1 class 7...
nutrition in plants chapter 1 class 7...nutrition in plants chapter 1 class 7...
nutrition in plants chapter 1 class 7...
 
8+8+8 Rule Of Time Management For Better Productivity
8+8+8 Rule Of Time Management For Better Productivity8+8+8 Rule Of Time Management For Better Productivity
8+8+8 Rule Of Time Management For Better Productivity
 
Diversity Quiz Finals by Quiz Club, IIT Kanpur
Diversity Quiz Finals by Quiz Club, IIT KanpurDiversity Quiz Finals by Quiz Club, IIT Kanpur
Diversity Quiz Finals by Quiz Club, IIT Kanpur
 

Lecture 1-3.ppt

  • 2. Course Objectives  The aim is not to make you the expert of computer programming but only the basics of computer programming.  To familiarize students with the use of C++.  To equip students with tools and techniques to implement a given problem programmatically
  • 4. Recommended Book  Problem Solving with C++ 10th edition by Walter Savitch- Pearson Prentice-Hall  C++ Programming from Problem Analysis to Program Design, 7th Edition, By, DS Malik  Programming in C++ by Dietel and Dietal  Programming in C++ by Robert Laphore  Lecture Handouts
  • 5. IDEs used for this course  You can use any of the IDEs given below; but we will use Dev C++ in the classes and Labs  DEV C++  Visual C++  Turbo C++
  • 6. Grading Criteria Mid Term = 20% Final Exam = 50% Quizzes = 5% CP & CB = 5% Assignments = 10% Project = 10%
  • 8. Topics to be Covered  Computer Systems  Programing & Problem Solving  Introduction to C++
  • 10. Computer Systems  Hardware: Physical devices  Software: Instructions and computer programs
  • 11. Hardware  Input : Keyboard, Mouse  Central Processing Unit (CPU)  Main Memory: Random Access Memory (RAM)  Output: Monitor, Printer  Secondary Storage: Disk Drive
  • 12. Main Components of a Computer
  • 14. Software  Instructions for the hardware.  Actions to be performed  A set of instructions is called a program.  Driving force behind the computer  Without a program – What is a computer? ▪ Collection of Useless Hardware  2 purposes:  Tell the computer what to do  Tell other people what we want the computer to do.
  • 15. Programming Language  Digital devices have two stable states, zero and one  A single digit (0 or 1) is called a bit, short for binary digit. A byte is made up of 8 bits.  Binary Language: Data and instructions (numbers, characters, strings, etc.) are encoded as binary numbers - a series of bits, called byte.
  • 16. Homework (1 Mark) Task 1  Search about Quantum computing and make a 1 page summary in which you have to write its working and how it makes a difference from conventional computing?  Deadline : 9-09-2022
  • 17. Programming Languages  Computers can not use human languages, and programming in the binary language of computers is a very difficult, tedious process  Therefore, most programs are written using a programming language and are converted to the binary language used by the computer
  • 18.  Three major categories of prog languages:  Machine Language  Assembly Language  High level Language
  • 19. Machine Language  Natural language of a particular computer  Primitive instructions built into every computer  The instructions are in the form of binary code  Any other types of languages must be translated down to this level  Example: 0110 1001 1010 1011
  • 20. Assembly Languages  English-like Abbreviations used for operations ADD X Y Z  Assembly languages were developed to make programming easier  The computer cannot understand assembly language - a program called assembler is used to convert assembly language programs into machine code
  • 21. High Level Languages  English-like and easy to learn and program  Common mathematical notation  Total Cost = Price + Tax;  area = 5 * 5 * 3.1415;  Java, Python,C, C++, FORTRAN,COBOL, VISUAL BASIC, PASCAL
  • 22. Compilers  A compiler is a program that translates a high-level language program, such as a C++ program, into a machine-language program that the computer can directly understand and execute.
  • 24. What is Program and Programming ?  Program is a set of instructions, which performs any particular task.  Programming is a process of problem solving. Different people use different techniques to solve problems
  • 25. Problem Solving  The process of defining a problem, searching for relevant information and resources about the problem, and of discovering, designing, and evaluating the solutions for further opportunities. Includes:  Finding an Answer to a Question  Figuring out how to Perform a Task  Figure out how to Make Things Work  Not enough to know a particular programming language… Must be able to problem solve…
  • 26. Polya’s 4 Steps of Problem Solving  Problem Solving Phase  U – Understand the Problem  D – Devise a Good Plan to Solve  Implementation Phase  I – Implement the Plan  E – Evaluate the Solution
  • 27. Example  Determine how many times a name occurs in a list of names:
  • 28. Example  Determine how many times a name occurs in a list of names: 1. Get the list of names. 2. Get the name being checked. 3. Set a counter to zero. 4. Do the following for each name on the list: Compare the name on the list to the name being checked, and if the names are the same, then add one to the counter. 5. Announce that the answer is the number indicated by the counter.  The instructions numbered 1 through 5 is algorithm
  • 29. Algorithm  A sequence of precise instructions which leads to a solution is called an algorithm.  Some approximately equivalent words are recipe, method, directions, procedure, and routine.
  • 31.  Write an algorithm to serve as how-to instructions for given picture. Instructions should be 10-20 steps in length. Assume you are writing instructions who is ROBOT.
  • 32. Program Design  To produce a program in a programming language such as C++, the algorithm is translated into the programming language. Producing the final program from the algorithm is called the implementation phase.
  • 34. History and Introduction to C++  C++ is a programming language  It was developed by Dennis Riche at Bell’s Lab in 1971.  In C++, we can make new software or programs.
  • 35. History and Introduction to C++  Before C++, there were so many languages which were being used by the programmers like GW Basic, Pascal, and Fortran etc. But after the birth of C++, it becomes more famous than all other languages. So many of the programmers divorced the other languages and happily married with C++.
  • 36. Features of C Language  C++ is considered as High level language.  C++ is case sensitive language.  C++ has compiler as a language translator.  C++ is hybrid language (Combination of structured as well as Object orientation paradigm)
  • 37. Homework (1 Mark) Task 02  Search and write briefly about Generation of Programming languages.
  • 38. Terminologies  Computer Programming: The process of developing and implementing various sets of instructions to enable a computer to do a certain task is called Computer Programming.  Computer Program: A program is a set of step-by-step instructions that directs the computer what to do and how to do.  Computer Programmer: The one who is expert in writing computer programs or developing the software is called a computer programmer or developer.  Programming Language: A programming language is a formal constructed language designed to communicate instructions to a machine, particularly a computer.
  • 39. IDEs  An integrated development environment is a software application that provides comprehensive facilities to computer program  An IDE normally consists of at least a source code editor, build automation tools, and a debugger.
  • 40. Editor, Linker, Loader, Compiler, Debugger  IDE has editor, linker, compiler, loader, executer and debugger.  Editor: In editor we write the source code.  Compiler: Converts the source code in to machine code.  Linker: Linker links the object code with libraries.  Loader: Loader loads program in to the memory.  Executer: This unit executes the program.  Debugger: This unit helps in removing the defect or errors or logical errors.
  • 41.
  • 42. Recap of the lecture •Introduction to Computer •What is Program ? •History and Development of C-Language •Features of C-Language •Level and Generations of Programming Languages •Terminologies
  • 43. Recommended Readings Chapter No. 1 of Problem Solving with C++ 10th edition by Walter Savitch- Pearson Prentice-Hall & C++ Programming from Problem Analysis to Program Design written by DS Malik
  翻译: