Computer Systems Nat 4/5 Computing Science Translator Programs.

Slides:



Advertisements
Similar presentations
compilers and interpreters
Advertisements

CHAPTER 2 GC101 Program’s algorithm 1. COMMUNICATING WITH A COMPUTER  Programming languages bridge the gap between human thought processes and computer.
Computer Concepts 5th Edition Parsons/Oja Page 546 CHAPTER 11 Software Engineering Section A PARSONS/OJA Computer Programming.
Development of Computer - Story of Steve. What is a computer A high intelligence machine A tool – make our life much convenient A very loyal servant Pretty.
CS 104 Introduction to Computer Science and Graphics Problems Software and Programming Language (2) Programming Languages 09/26/2008 Yang Song (Prepared.
SOFTWARE SYSTEMS SOFTWARE APPLICATIONS SOFTWARE PROGRAMMING LANGUAGES.
1 Programming Languages Examples: C, Java, HTML, Haskell, Prolog, SAS Also known as formal languages Completely described and rigidly governed by formal.
Activity 1 - WBs 5 mins Go online and spend a moment trying to find out the difference between: HIGH LEVEL programming languages and LOW LEVEL programming.
CHAPTER 4: INTRODUCTION TO COMPUTER ORGANIZATION AND PROGRAMMING DESIGN Lec. Ghader Kurdi.
Copyright ©2005  Department of Computer & Information Science Introducing Programming.
© Janice Regan, CMPT 128, Jan CMPT 128 Introduction to Computing Science for Engineering Students Creating a program.
Systems Software & Operating systems
1 Software Development Topic 2 Software Development Languages and Environments.
General Computer Science for Engineers CISC 106 Lecture 02 Dr. John Cavazos Computer and Information Sciences 09/03/2010.
Standard Grade Computing SYSTEM SOFTWARE CHAPTER 19.
Slide 1 Standard Grade Computing Studies Systems Software.
Tranlators. Machine Language The lowest-level programming languageprogramming language Machine languages are the only languages understood by computers.languagescomputers.
Programming Language Rico Yu. Levels of Programming Languages 1.Low level languages 2.High level languages.
COMPUTER PROGRAMS AND LANGUAGES Chapter 4. Developing a computer program Programs are a set (series) of instructions Programmers determine The instructions.
Introduction to Programming ICS2O Findlay. Learning Goals  We will learn  The definitions of a computer, program and programming language.  The different.
TMF1013 : Introduction To Computing Lecture 1 : Fundamental of Computer ComputerFoudamentals.
The Teacher Computing Computer Languages [Computing]
A language which is acceptable to a computer system is called a computer language or programming language and the process of writing instructions in such.
1 3. Computing System Fundamentals 3.1 Language Translators.
Computer Programming Languages HOW COMPUTERS WORK èCIRCUITS èBINARY DIGIT èBIT (0 OR 1) èBYTE - 8 BITS èASCII.
A compiler is a computer program that translate written code (source code) into another computer language Associated with high level languages A well.
Compilers and Interpreters. HARDWARE Machine LanguageAssembly Language High Level Language C++ Visual Basic JAVA Humans.
 Computer Languages Computer Languages  Machine Language Machine Language  Assembly Language Assembly Language  High Level Language High Level Language.
The Functions and Purposes of Translators Translators, Interpreters and Compilers - High Level Languages.
Compilers and Interpreters
The Functions and Purposes of Translators Translators, Interpreters and Compilers - High Level Languages.
Software Engineering Algorithms, Compilers, & Lifecycle.
Chapter 2- Visual Basic Schneider1 Programming Languages: Machine Language Assembly Language High level Language.
Machine Language Computer languages cannot be directly interpreted by the computer – they are not in binary. All commands need to be translated into binary.
Programming Languages Salihu Ibrahim Dasuki (PhD) CSC102 INTRODUCTION TO COMPUTER SCIENCE.
Programming Language Basics. What is a Programming Language? “A computer, human-created language used to write instructions for a computer.” “An artificial.
Introduction to computer software. Programming the computer Program, is a sequence of instructions, written to perform a specified task on a computer.
CHAPTER 2 GC101 Program’s algorithm 1. COMMUNICATING WITH A COMPUTER  Programming languages bridge the gap between human thought processes and computer.
Evolution and History of Programming Languages
Computer Systems Nat 5 Computing Science
Computer Systems Nat 4/5 Computing Science
Topic: Programming Languages and their Evolution + Intro to Scratch
Unit 2.5 Translators and Facilities of Languages – Lesson 1
High and low level languages
Programming Languages
Introduction to programming
CSCI-235 Micro-Computer Applications
Computer Systems Nat 5 Computing Science
C Programming Language
Problem Solving Using C: Orientation & Lecture 1
A451 Theory – 7 Programming 7A, B - Algorithms.
Chapter 1 Preliminaries.
TRANSLATORS AND IDEs Key Revision Points.
Translators & Facilities of Languages
Language is a medium of communication.
Assembler, Compiler, Interpreter
Problem Solving.
CSC128 FUNDAMENTALS OF COMPUTER PROBLEM SOLVING
High Level Programming Languages
Unit 1: Introduction Lesson 1: PArts of a java program
Lesson Objectives Aims Key Words Compiler, interpreter, assembler
صياغة البرامج ولغات البرمجة Programming & programming languages
Translators & Types of Languages
Assembler, Compiler, Interpreter
Programming Language Basics
PROGRAMMING FUNDAMENTALS Lecture # 03. Programming Language A Programming language used to write computer programs. Its mean of communication between.
ICT Programming Lesson 1:
Nat 4/5 Computing Science Translator Programs
1.3.7 High- and low-level languages and their translators
Presentation transcript:

Computer Systems Nat 4/5 Computing Science Translator Programs

Lesson Aims  By the end of this lesson:  All pupils will be able to:  Describe and compare the following types of languages:  Machine Code  High Level Languages  Describe why High Level Languages require translation.  Describe how interpreters and compilers function.

Types Of Languages  Machine Code is made up of only 2 symbols.  1 and 0 (On and Off)  High Level Languages such as Visual Basic are written using some English words.  They are not written IN english! Nat 4/5

High Level Languages Nat 4/5 General Purpose Pascal, C, C++ and COMAL ALGOL (Initially used for Mainframes) Artificial Intelligence PROLOG (PROgramming in LOGic) LISP (Probably 2 nd oldest language still in use ) Education Pascal COMAL BASIC Operating Systems C C++,C#

Why do we need them?  The source code you write is instructions for the computer  They are in a High Level Language  The computer needs these instructions translated into machine code  It’s the only language it understands! Nat 4/5

Types of Translators  These programs convert High Level Language Source code into machine code (binary)  Interpreter  Translates and executes one line at a time  Compiler  Translates and executes the entire program at once  This program can then be ran repeatedly Nat 4/5 Think complete!

Interpreter  Functions like a spoken language interpreter.  Translates and executes a single line at a time  The interpreter is ALWAYS loaded in memory  Error feedback is provided line by line  Like in Smallbasic  Interpreted programs have to be re- interpreted every single execution Nat 4/5

How an interpreter works Nat 4/5 Original Source Code Pctoutput.print “Hello” Pctoutput.isible = true Interpreter Syntax Error

How the compiler works Nat 4/5 Original Source Code Pctoutput.print “Hello” Pctoutput.isible = true Compiler Syntax Error Object Code Can be saved and ran later

Summary  Compilers translate source code once into an executable program  Only has to be translated once!  Cannot see the source code in a compiled program  Interpreters translate source code line by line  Always has to be re-interpreted  Spots errors line by line Nat 4/5