SlideShare a Scribd company logo

An overview of computers and programming languages

1 of 36
Download to read offline
Chapter 1:An Overview of
Computers and Programming
Languages
Java Programming:
From Problem Analysis to Program Design,
Second Edition
Chapter Objectives
 Learn about different types of computers.
 Explore the hardware and software components of a computer system.
 Learn about the language of a computer.
 Learn about the evolution of programming languages.
 Examine high-level programming languages.
 Discover what a compiler is and what it does.
2
Chapter Objectives
 Examine a Java program.
 Examine how a Java program is processed.
 Become aware of the Internet and World Wide Web.
 Learn what an algorithm is and explore problem-solving techniques.
 Become aware of structured and object-oriented programming design
methodologies.
3
Introduction
 Computers have greatly affected our daily lives—
helping us complete many tasks.
 Computer programs (software) are designed specifically
for each task.
 Software is created with programming languages.
 Java is an example of a programming language.
4
An Overview of the
History of Computers
 1950s: Very large devices available to a select few.
 1960s: Large corporations owned computers.
 1970s: Computers got smaller and cheaper.
 1990s: Computers got cheaper and faster and were found in most homes.
5
Elements of a Computer
System
A computer has two components:
Hardware
Software
6

Recommended

More Related Content

What's hot

Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programmingNeeru Mittal
 
Introduction to Compiler Construction
Introduction to Compiler Construction Introduction to Compiler Construction
Introduction to Compiler Construction Sarmad Ali
 
Compiler vs interpreter
Compiler vs interpreterCompiler vs interpreter
Compiler vs interpreterKamal Tamang
 
System Programming- Unit I
System Programming- Unit ISystem Programming- Unit I
System Programming- Unit ISaranya1702
 
Compiler Design
Compiler DesignCompiler Design
Compiler DesignMir Majid
 
History of Programming Language
History of Programming LanguageHistory of Programming Language
History of Programming Languagetahria123
 
System Programing Unit 1
System Programing Unit 1System Programing Unit 1
System Programing Unit 1Manoj Patil
 
Algorithm defination, design & Implementation
Algorithm defination, design & ImplementationAlgorithm defination, design & Implementation
Algorithm defination, design & ImplementationBilal Maqbool ツ
 
Programming Fundamental Presentation
Programming Fundamental PresentationProgramming Fundamental Presentation
Programming Fundamental Presentationfazli khaliq
 
Techniques & applications of Compiler
Techniques & applications of CompilerTechniques & applications of Compiler
Techniques & applications of CompilerPreethi AKNR
 
Chapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to ProgrammingChapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to Programmingmshellman
 
Presentation on C++ Programming Language
Presentation on C++ Programming LanguagePresentation on C++ Programming Language
Presentation on C++ Programming Languagesatvirsandhu9
 
Introduction to system programming
Introduction to system programmingIntroduction to system programming
Introduction to system programmingsonalikharade3
 
4 evolution-of-programming-languages
4 evolution-of-programming-languages4 evolution-of-programming-languages
4 evolution-of-programming-languagesRohit Shrivastava
 

What's hot (20)

Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programming
 
Programming Language
Programming LanguageProgramming Language
Programming Language
 
Computer Programming
Computer ProgrammingComputer Programming
Computer Programming
 
Introduction to Compiler Construction
Introduction to Compiler Construction Introduction to Compiler Construction
Introduction to Compiler Construction
 
Computer programming
Computer programmingComputer programming
Computer programming
 
System programming
System programmingSystem programming
System programming
 
Compiler vs interpreter
Compiler vs interpreterCompiler vs interpreter
Compiler vs interpreter
 
System Programming- Unit I
System Programming- Unit ISystem Programming- Unit I
System Programming- Unit I
 
Compiler Construction
Compiler ConstructionCompiler Construction
Compiler Construction
 
Compiler Design
Compiler DesignCompiler Design
Compiler Design
 
History of Programming Language
History of Programming LanguageHistory of Programming Language
History of Programming Language
 
System Programing Unit 1
System Programing Unit 1System Programing Unit 1
System Programing Unit 1
 
Algorithm defination, design & Implementation
Algorithm defination, design & ImplementationAlgorithm defination, design & Implementation
Algorithm defination, design & Implementation
 
Programming Fundamental Presentation
Programming Fundamental PresentationProgramming Fundamental Presentation
Programming Fundamental Presentation
 
Techniques & applications of Compiler
Techniques & applications of CompilerTechniques & applications of Compiler
Techniques & applications of Compiler
 
Chapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to ProgrammingChapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to Programming
 
Presentation on C++ Programming Language
Presentation on C++ Programming LanguagePresentation on C++ Programming Language
Presentation on C++ Programming Language
 
Compiler Chapter 1
Compiler Chapter 1Compiler Chapter 1
Compiler Chapter 1
 
Introduction to system programming
Introduction to system programmingIntroduction to system programming
Introduction to system programming
 
4 evolution-of-programming-languages
4 evolution-of-programming-languages4 evolution-of-programming-languages
4 evolution-of-programming-languages
 

Viewers also liked

C++ Programming Language
C++ Programming Language C++ Programming Language
C++ Programming Language Mohamed Loey
 
Whats new in IIB v9 + Open Beta v10 GSE
Whats new in IIB v9 + Open Beta v10 GSEWhats new in IIB v9 + Open Beta v10 GSE
Whats new in IIB v9 + Open Beta v10 GSEDominic Storey
 
Basic qualities of a good businessman
Basic qualities of a good businessmanBasic qualities of a good businessman
Basic qualities of a good businessmanAhmad Idrees
 
Control structures ii
Control structures ii Control structures ii
Control structures ii Ahmad Idrees
 
Basic characteristics of business
Basic characteristics of businessBasic characteristics of business
Basic characteristics of businessAhmad Idrees
 
What is computer Introduction to Computing
What is computer Introduction  to Computing What is computer Introduction  to Computing
What is computer Introduction to Computing Ahmad Idrees
 
Whats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CD
Whats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CDWhats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CD
Whats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CDDavid Ware
 
Control structures in C++ Programming Language
Control structures in C++ Programming LanguageControl structures in C++ Programming Language
Control structures in C++ Programming LanguageAhmad Idrees
 
Strategic planning and mission statement
Strategic planning and mission statement Strategic planning and mission statement
Strategic planning and mission statement Ahmad Idrees
 
Basic elements of java
Basic elements of java Basic elements of java
Basic elements of java Ahmad Idrees
 
Basic c++ programs
Basic c++ programsBasic c++ programs
Basic c++ programsharman kaur
 
Basics of c++ Programming Language
Basics of c++ Programming LanguageBasics of c++ Programming Language
Basics of c++ Programming LanguageAhmad Idrees
 
System outputs - Computer System
System outputs - Computer SystemSystem outputs - Computer System
System outputs - Computer SystemAhmad Idrees
 
Principle of marketing
Principle of marketing Principle of marketing
Principle of marketing Ahmad Idrees
 
Effective writing, tips for Bloggers
Effective writing, tips for BloggersEffective writing, tips for Bloggers
Effective writing, tips for BloggersAhmad Idrees
 
Introduction to objects and inputoutput
Introduction to objects and inputoutput Introduction to objects and inputoutput
Introduction to objects and inputoutput Ahmad Idrees
 
Intro. to prog. c++
Intro. to prog. c++Intro. to prog. c++
Intro. to prog. c++KurdGul
 

Viewers also liked (20)

C++ Programming Language
C++ Programming Language C++ Programming Language
C++ Programming Language
 
Whats new in IIB v9 + Open Beta v10 GSE
Whats new in IIB v9 + Open Beta v10 GSEWhats new in IIB v9 + Open Beta v10 GSE
Whats new in IIB v9 + Open Beta v10 GSE
 
Basic qualities of a good businessman
Basic qualities of a good businessmanBasic qualities of a good businessman
Basic qualities of a good businessman
 
Control structures ii
Control structures ii Control structures ii
Control structures ii
 
Basic characteristics of business
Basic characteristics of businessBasic characteristics of business
Basic characteristics of business
 
What is computer Introduction to Computing
What is computer Introduction  to Computing What is computer Introduction  to Computing
What is computer Introduction to Computing
 
Whats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CD
Whats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CDWhats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CD
Whats new in IBM MQ; V9 LTS, V9.0.1 CD and V9.0.2 CD
 
Control structures in C++ Programming Language
Control structures in C++ Programming LanguageControl structures in C++ Programming Language
Control structures in C++ Programming Language
 
Strategic planning and mission statement
Strategic planning and mission statement Strategic planning and mission statement
Strategic planning and mission statement
 
Basic elements of java
Basic elements of java Basic elements of java
Basic elements of java
 
Basic c++ programs
Basic c++ programsBasic c++ programs
Basic c++ programs
 
IBM MQ V9 Overview
IBM MQ V9 OverviewIBM MQ V9 Overview
IBM MQ V9 Overview
 
Basics of c++ Programming Language
Basics of c++ Programming LanguageBasics of c++ Programming Language
Basics of c++ Programming Language
 
System outputs - Computer System
System outputs - Computer SystemSystem outputs - Computer System
System outputs - Computer System
 
What is business
What is businessWhat is business
What is business
 
C++ ppt
C++ pptC++ ppt
C++ ppt
 
Principle of marketing
Principle of marketing Principle of marketing
Principle of marketing
 
Effective writing, tips for Bloggers
Effective writing, tips for BloggersEffective writing, tips for Bloggers
Effective writing, tips for Bloggers
 
Introduction to objects and inputoutput
Introduction to objects and inputoutput Introduction to objects and inputoutput
Introduction to objects and inputoutput
 
Intro. to prog. c++
Intro. to prog. c++Intro. to prog. c++
Intro. to prog. c++
 

Similar to An overview of computers and programming languages

Programming_Fundamentals_Chapter_1_INTRO.pdf
Programming_Fundamentals_Chapter_1_INTRO.pdfProgramming_Fundamentals_Chapter_1_INTRO.pdf
Programming_Fundamentals_Chapter_1_INTRO.pdfBernardVelasco1
 
Computer and programing basics.pptx
Computer and programing basics.pptxComputer and programing basics.pptx
Computer and programing basics.pptxgaafergoda
 
Introduction.pptx
Introduction.pptxIntroduction.pptx
Introduction.pptxSUDHAKAR S
 
LKGtoPG - Basics of C Language
LKGtoPG - Basics of  C LanguageLKGtoPG - Basics of  C Language
LKGtoPG - Basics of C Languagelkgtopg jobs
 
1.Overview of Programming.pptx
1.Overview of Programming.pptx1.Overview of Programming.pptx
1.Overview of Programming.pptxVishwas459764
 
Programming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages ConceptsProgramming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages Conceptsimtiazalijoono
 
Btech i pic u-1 introduction to c language
Btech i pic u-1 introduction to c languageBtech i pic u-1 introduction to c language
Btech i pic u-1 introduction to c languageRai University
 
Mca i pic u-1 introduction to c language
Mca i pic u-1 introduction to c languageMca i pic u-1 introduction to c language
Mca i pic u-1 introduction to c languageRai University
 
introduction to c language
 introduction to c language introduction to c language
introduction to c languageRai University
 
Diploma ii cfpc u-1 introduction to c language
Diploma ii  cfpc u-1 introduction to c languageDiploma ii  cfpc u-1 introduction to c language
Diploma ii cfpc u-1 introduction to c languageRai University
 
Bsc cs i pic u-1 introduction to c language
Bsc cs i pic u-1 introduction to c languageBsc cs i pic u-1 introduction to c language
Bsc cs i pic u-1 introduction to c languageRai University
 
Fundamentals of programming with C++
Fundamentals of programming with C++Fundamentals of programming with C++
Fundamentals of programming with C++Seble Nigussie
 
Introduction to programming principles languages
Introduction to programming principles languagesIntroduction to programming principles languages
Introduction to programming principles languagesFrankie Jones
 
Computer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika Tripathi
Computer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika TripathiComputer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika Tripathi
Computer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika TripathiProf. (Dr.) Anand K. Tripathi
 

Similar to An overview of computers and programming languages (20)

CISY 105 Chapter 1
CISY 105 Chapter 1CISY 105 Chapter 1
CISY 105 Chapter 1
 
Programming_Fundamentals_Chapter_1_INTRO.pdf
Programming_Fundamentals_Chapter_1_INTRO.pdfProgramming_Fundamentals_Chapter_1_INTRO.pdf
Programming_Fundamentals_Chapter_1_INTRO.pdf
 
Computer and programing basics.pptx
Computer and programing basics.pptxComputer and programing basics.pptx
Computer and programing basics.pptx
 
Introduction.pptx
Introduction.pptxIntroduction.pptx
Introduction.pptx
 
LKGtoPG - Basics of C Language
LKGtoPG - Basics of  C LanguageLKGtoPG - Basics of  C Language
LKGtoPG - Basics of C Language
 
01CHAP_1.PPT
01CHAP_1.PPT01CHAP_1.PPT
01CHAP_1.PPT
 
1.Overview of Programming.pptx
1.Overview of Programming.pptx1.Overview of Programming.pptx
1.Overview of Programming.pptx
 
Programming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages ConceptsProgramming Fundamentals and Programming Languages Concepts
Programming Fundamentals and Programming Languages Concepts
 
Computer Programming - Lecture 1
Computer Programming - Lecture 1Computer Programming - Lecture 1
Computer Programming - Lecture 1
 
Btech i pic u-1 introduction to c language
Btech i pic u-1 introduction to c languageBtech i pic u-1 introduction to c language
Btech i pic u-1 introduction to c language
 
Mca i pic u-1 introduction to c language
Mca i pic u-1 introduction to c languageMca i pic u-1 introduction to c language
Mca i pic u-1 introduction to c language
 
Software Concepts Notes
Software Concepts NotesSoftware Concepts Notes
Software Concepts Notes
 
introduction to c language
 introduction to c language introduction to c language
introduction to c language
 
Diploma ii cfpc u-1 introduction to c language
Diploma ii  cfpc u-1 introduction to c languageDiploma ii  cfpc u-1 introduction to c language
Diploma ii cfpc u-1 introduction to c language
 
Caim ppt
Caim pptCaim ppt
Caim ppt
 
Bsc cs i pic u-1 introduction to c language
Bsc cs i pic u-1 introduction to c languageBsc cs i pic u-1 introduction to c language
Bsc cs i pic u-1 introduction to c language
 
Fundamentals of programming with C++
Fundamentals of programming with C++Fundamentals of programming with C++
Fundamentals of programming with C++
 
Fundamentals of Programming Chapter 2
Fundamentals of Programming Chapter 2Fundamentals of Programming Chapter 2
Fundamentals of Programming Chapter 2
 
Introduction to programming principles languages
Introduction to programming principles languagesIntroduction to programming principles languages
Introduction to programming principles languages
 
Computer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika Tripathi
Computer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika TripathiComputer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika Tripathi
Computer Programming By Prof.(Dr.) Anand K. Tripathi ,Mrs Monika Tripathi
 

More from Ahmad Idrees

Control structures i
Control structures i Control structures i
Control structures i Ahmad Idrees
 
Marketing research links consumer
Marketing research links consumer Marketing research links consumer
Marketing research links consumer Ahmad Idrees
 
Marketing mix and 4 p's
Marketing mix and 4 p's Marketing mix and 4 p's
Marketing mix and 4 p's Ahmad Idrees
 
Managing marketing information
Managing marketing information Managing marketing information
Managing marketing information Ahmad Idrees
 
Swot analysis Marketing Principle
Swot analysis Marketing Principle Swot analysis Marketing Principle
Swot analysis Marketing Principle Ahmad Idrees
 
C++ programming program design including data structures
C++ programming program design including data structures C++ programming program design including data structures
C++ programming program design including data structures Ahmad Idrees
 
Top 40 seo myths everyone should know about
Top 40 seo myths everyone should know aboutTop 40 seo myths everyone should know about
Top 40 seo myths everyone should know aboutAhmad Idrees
 

More from Ahmad Idrees (7)

Control structures i
Control structures i Control structures i
Control structures i
 
Marketing research links consumer
Marketing research links consumer Marketing research links consumer
Marketing research links consumer
 
Marketing mix and 4 p's
Marketing mix and 4 p's Marketing mix and 4 p's
Marketing mix and 4 p's
 
Managing marketing information
Managing marketing information Managing marketing information
Managing marketing information
 
Swot analysis Marketing Principle
Swot analysis Marketing Principle Swot analysis Marketing Principle
Swot analysis Marketing Principle
 
C++ programming program design including data structures
C++ programming program design including data structures C++ programming program design including data structures
C++ programming program design including data structures
 
Top 40 seo myths everyone should know about
Top 40 seo myths everyone should know aboutTop 40 seo myths everyone should know about
Top 40 seo myths everyone should know about
 

An overview of computers and programming languages

  • 1. Chapter 1:An Overview of Computers and Programming Languages Java Programming: From Problem Analysis to Program Design, Second Edition
  • 2. Chapter Objectives  Learn about different types of computers.  Explore the hardware and software components of a computer system.  Learn about the language of a computer.  Learn about the evolution of programming languages.  Examine high-level programming languages.  Discover what a compiler is and what it does. 2
  • 3. Chapter Objectives  Examine a Java program.  Examine how a Java program is processed.  Become aware of the Internet and World Wide Web.  Learn what an algorithm is and explore problem-solving techniques.  Become aware of structured and object-oriented programming design methodologies. 3
  • 4. Introduction  Computers have greatly affected our daily lives— helping us complete many tasks.  Computer programs (software) are designed specifically for each task.  Software is created with programming languages.  Java is an example of a programming language. 4
  • 5. An Overview of the History of Computers  1950s: Very large devices available to a select few.  1960s: Large corporations owned computers.  1970s: Computers got smaller and cheaper.  1990s: Computers got cheaper and faster and were found in most homes. 5
  • 6. Elements of a Computer System A computer has two components: Hardware Software 6
  • 7. Hardware Components of a Computer  Central processing unit (CPU)  Main memory 7
  • 8. Central Processing Unit  Control unit (CU)  Arithmetic logic unit (ALU)  Program counter (PC)  Instruction register (IR) 8
  • 10. Main Memory  Ordered sequence of cells (memory cells).  Directly connected to CPU.  All programs must be brought into main memory before execution.  When power is turned off, everything in main memory is lost. 10
  • 11. Main Memory with 100 Storage Cells 11
  • 12. Secondary Storage  Provides permanent storage for information.  Examples of secondary storage:  Hard disks  Floppy disks  Zip disks  CD-ROMs  Tapes 12
  • 13. Input Devices  Devices that feed data and computer programs into computers.  Examples:  Keyboard  Mouse  Secondary storage 13
  • 14. Output Devices  Devices that the computer uses to display results.  Examples:  Printer  Monitor  Secondary storage 14
  • 15. Software  Software consists of programs written to perform specific tasks.  Two types of programs:  System programs  Application programs 15
  • 16. System Programs  System programs control the computer.  The operating system is first to load when you turn on a computer. 16
  • 17. Operating System (OS)  The OS monitors the overall activity of the computer and provides services.  Example services:  Memory management  Input/output  Activities  Storage management 17
  • 18. Application Programs  Written using programming languages.  Perform a specific task.  Run by the OS.  Example programs:  Word processors  Spreadsheets  Games 18
  • 19. Language of a Computer  Machine language is the most basic language of a computer.  A sequence of 0s and 1s.  Every computer directly understands its own machine language.  A bit is a binary digit, 0 or 1.  A byte is a sequence of eight bits. 19
  • 20. Language of a Computer 20
  • 21. Evolution of Programming Languages  Early computers programmed in machine language.  Assembly languages were developed to make programmer’s job easier.  In assembly language, an instruction is an easy-to-remember form called a mnemonic.  Assembler: Translates assembly language instructions into machine language. 21
  • 22. Instructions in Assembly and Machine Languages 22
  • 23. Evolution of Programming Languages  High-level languages make programming easier.  Closer to spoken languages.  Examples:  Basic  FORTRAN  COBOL  C/C++  Java 23
  • 24. Evolution of Programming Languages To run a Java program: 1. Java instructions need to be translated into an intermediate language called bytecode. 2. The bytecode is interpreted into a particular machine language. 24
  • 25. Evolution of Programming Languages  Compiler: A program that translates a program written in a high- level language into the equivalent machine language.  (In the case of Java, this machine language is the bytecode.)  Java Virtual Machine (JVM): A hypothetical computer developed to make Java programs machine independent. 25
  • 26. A Java Program public class ASimpleJavaProgram { public static void main(String[] args) { System.out.println("My first Java program."); System.out.println("The sum of 2 and 3 = " + 5); System.out.println("7 + 8 = " + (7 + 8)); } } Sample Run: My first Java program. The sum of 2 and 3 = 5 7 + 8 = 15 26
  • 27. Processing a Java Program  Two types of Java programs are applications and applets.  Source program: Written in a high-level language.  Loader: Transfers the compiled code (bytecode) into main memory.  Interpreter: Reads and translates each bytecode instruction into machine language and then executes it. 27
  • 28. Processing a Java Program 28
  • 29. Problem-Analysis-Coding- Execution Cycle  Algorithm: A step-by-step, problem-solving process in which a solution is arrived at in a finite amount of time. 29
  • 30. Problem-Solving Process 1. Analyze the problem: Outline solution requirements and design an algorithm. 2. Implement the algorithm in a programming language (Java) and verify that the algorithm works. 3. Maintain the program: Use and modify if the problem domain changes. 30
  • 32. Programming Methodologies Two basic approaches to programming design:  Structured design  Object-oriented design 32
  • 33. Structured Design 1. A problem is divided into smaller sub-problems. 2. Each sub-problem is solved. 3. The solutions of all sub-problems are combined to solve the problem. 33
  • 34. Object-Oriented Design (OOD)  In OOD, a program is a collection of interacting objects.  An object consists of data and operations.  Steps in OOD: 1. Identify objects. 2. Form the basis of the solution. 3. Determine how these objects interact. 34
  • 35. Chapter Summary  A computer system is made up of hardware and software components.  Computers understand machine language; it is easiest for programmers to write in high-level languages.  A compiler translates high-level language into machine language.  The Java steps required to execute a program are edit, compile, load, and execute. 35
  • 36. Chapter Summary  An algorithm is a step-by-step, problem-solving process in which a solution is arrived at in a finite amount of time.  The three steps of the problem-solving process are analyze the problem and design an algorithm, implement the algorithm in a programming language, and maintain the program.  The two basic approaches to programming design are structured design and object-oriented design. 36