C021TV-I3-S2.

Slides:



Advertisements
Similar presentations
compilers and interpreters
Advertisements

OO Programming in Java Objectives for today: Overriding the toString() method Polymorphism & Dynamic Binding Interfaces Packages and Class Path.
Fundamentals of Computer and programming in C Programming Languages, Programs and Programming Rohit Khokher.
Languages for IT & CS Pseudo-code What HTML isn’t Early history Compiling & interpreting Classifying languages The process of programming.
Write a program step by step. Step 1: Problem definition. Given the coordinate of two points in 2-D space, compute and print their straight distance.
IT253: Computer Organization Lecture 6: Assembly Language and MIPS: Programming Tonga Institute of Higher Education.
Stacks - 3 Nour El-Kadri CSI Evaluating arithmetic expressions Stack-based algorithms are used for syntactical analysis (parsing). For example.
Chapter 1: An Overview of Computers and Programming Languages
Programming Types of Testing.
Creating Computer Programs lesson 27. This lesson includes the following sections: What is a Computer Program? How Programs Solve Problems Two Approaches:
Perl Practical Extraction and Report Language Senior Projects II Jeff Wilson.
By Neng-Fa Zhou Compiler Construction CIS 707 Prof. Neng-Fa Zhou
1 Programming Languages b Each type of CPU has its own specific machine language b But, writing programs in machine languages is cumbersome (too detailed)
Chapter 16 Programming and Languages: Telling the Computer What to Do.
Compilers and Interpreters. Translation to machine language Every high level language needs to be translated to machine code There are different ways.
Overview of program analysis Mooly Sagiv html://
Programming. Software is made by programmers Computers need all kinds of software, from operating systems to applications People learn how to tell the.
Programming Concepts and Languages Chapter 12 – Computers: Understanding Technology, 3 rd edition 1November
C++ Programming: From Problem Analysis to Program Design, Fifth Edition Chapter 1: An Overview of Computers and Programming Languages Updated by: Dr\Ali-Alnajjar.
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.
PRINCIPLES OF PROGRAMMING Revision. A Computer  A useful tool for solving a great variety of problems.  To make a computer do anything (i.e. solve.
Python Mini-Course University of Oklahoma Department of Psychology Day 1 – Lesson 2 Fundamentals of Programming Languages 4/5/09 Python Mini-Course: Day.
Introduction to Programming Lecture Number:. What is Programming Programming is to instruct the computer on what it has to do in a language that the computer.
© Janice Regan, CMPT 128, Jan CMPT 128 Introduction to Computing Science for Engineering Students Creating a program.
Parser-Driven Games Tool programming © Allan C. Milne Abertay University v
Lesson 6. GCSE Computing – programming languages Candidates should be able to:  describe common tools and facilities available in an integrated development.
IXA 1234 : C++ PROGRAMMING CHAPTER 1. PROGRAMMING LANGUAGE Programming language is a computer program that can solve certain problem / task Keyword: Computer.
What am I?. Translators Translators – Module Knowledge Areas Types of translators and their use Lexical analysis Syntax analysis Code generation and.
J ava P rogramming: From Problem Analysis to Program Design, From Problem Analysis to Program Design, Second Edition Second Edition D.S. Malik D.S. Malik.
CS 460/660 Compiler Construction. Class 01 2 Why Study Compilers? Compilers are important – –Responsible for many aspects of system performance Compilers.
Component 4: Introduction to Information and Computer Science Unit 5: Overview of Programming Languages, Including Basic Programming Concepts Lecture 2.
Chapter 1: Introduction 1 Compiler Designs and Constructions Chapter 1: Introduction Objectives: Course Objectives Introduction Dr. Mohsen Chitsaz.
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.
How to Program? -- Part 1 Part 1: Problem Solving –Analyze a problem –Decide what steps need to be taken to solve it. –Take into consideration any special.
 Computer Languages Computer Languages  Machine Language Machine Language  Assembly Language Assembly Language  High Level Language High Level Language.
This Week Lecture on relational semantics Exercises on logic and relations Labs on using Isabelle to do proofs.
Compilers and Interpreters
CHAPTER 3 COMPLETING THE PROBLEM- SOLVING PROCESS AND GETTING STARTED WITH C++ An Introduction to Programming with C++ Fifth Edition.
Programming 2 Intro to Java Machine code Assembly languages Fortran Basic Pascal Scheme CC++ Java LISP Smalltalk Smalltalk-80.
Debuggers. Errors in Computer Code Errors in computer programs are commonly known as bugs. Three types of errors in computer programs –Syntax errors –Runtime.
3/5/2002e-business and Information Systems1 Introduction Computer System Hardware Software HW Kernel/OS API Application Programs SW.
Chapter 5: Preparing C Programs
Why don’t programmers have to program in machine code?
Chapter 5- Assembling , Linking, and Executing Programs
Introduction to programming
Problem Identification
Unit 2.5 Translators and Facilities of Languages – Lesson 2
Software Design and Development
Entry Ticket: High and Low Level Languages
Programming Concepts and Languages
Compiler Lecture 1 CS510.
and Executing Programs
Introduction to System Programming
Hello World 2 What does all that mean?.
Mobile Development Workshop
High Level Programming Languages
Unit 1: Introduction Lesson 1: PArts of a java program
Algorithms Take a look at the worksheet. What do we already know, and what will we have to learn in this term?
Programming.
Creating Computer Programs
C021TV-I3-S1.
Tonga Institute of Higher Education IT 141: Information Systems
Tonga Institute of Higher Education IT 141: Information Systems
Creating Computer Programs
Programming language translators
Dasar-Dasar Pemrograman 2: Java Basics
Introduction to Computer Science
Presentation transcript:

C021TV-I3-S2

I.3 Programming Machine code Bugs Humans and languages Higher level language and compilation Bugs Humans and languages

Compilation ? Idea 2

Compilation ? Idea ⇓ Main aspects 2

Algorithm + data structure Compilation ? Idea ⇓ Main apsects Algorithm + data structure 2

Algorithm + data structure Compilation ? Idea ⇓ Main apsects Algorithm + data structure Program 2

Algorithm + data structure Compilation ? Idea ⇓ Main aspects Algorithm + data structure Program Machine code 2

Algorithm + data structure Compilation ? Idea ⇓ Main apsects Algorithm + data structure Program ⇓ Compilation Machine code 2

Compiler? A compiler is a program! As a first approximation, It takes a text in a specific language (C, C++, OCaml. . .) It sends back either a text or an executable as an assembler. There are also interpreted languages where the program is dynamically executed by the interpreter.

Compiler ++ Moreover, the compiler Checks there are no syntax errors Checks there are no type errors (depends on the language) Can check a certain number of simple criteria and issue warnings (such as unused variables). So it checks(at least) that the program can be transformed into an executable. 4

Compiler ++ Moreover, the compiler Checks there are no syntax errors Checks there are no type errors (depends on the language) Can check a certain number of simple criteria and issue warnings (such as unused variables). So it checks(at least) that the program can be transformed into an executable. But that does not guarantee the program will do what we want it to do! 4