Professional Documents
Culture Documents
Programming Languages
Learning Objectives:
- characteristics and purpose of
different levels of programming
language, including low-level
languages
- the purpose of translators
- the characteristics of an assembler, a
compiler and an interpreter Introduction
- common tools and facilities available
in an integrated development
environment (IDE): CPUs are very impressive but they are actually quite simple when it
o editors
comes to processing.
o error diagnostics
o run-time environment
o translators.
They can only process 1’s and 0’s.
So what has to happen to get our code into a form that the CPU can
work with…?
GCSE 9-1: OCR Computer Science
Programming Languages
Learning Objectives:
- characteristics and purpose of
different levels of programming
language, including low-level Difference between high level and low level code…
languages
- the purpose of translators
- the characteristics of an assembler, a Machine Code (Very Low Level Language)
compiler and an interpreter
- common tools and facilities available
in an integrated development The CPU can only understand one type of
environment (IDE):
o editors code: Machine Code
o error diagnostics
o run-time environment
o translators. Made up of Coded Instructions and Data
Assembly Language
Hardware (CPU)
GCSE 9-1: OCR Computer Science
Programming Languages
Learning Objectives:
- characteristics and purpose of
different levels of programming
language, including low-level Difference between high level and low level code…
languages
- the purpose of translators Assembly Language (Low Level Language)
- the characteristics of an assembler, a
compiler and an interpreter
- common tools and facilities available
in an integrated development This language has a small set of commands which represent certain pieces of machine
environment (IDE): code
o editors
o error diagnostics
This helped programmers as they didn’t have to remember sets of binary code,
o run-time environment
o translators. instead they learnt commands.
EG: Instead of memorising what 1011 or 1001 meant, they just had to remember
commands like ADD and SUB
Assembly language is still quite difficult to learn and use and this is why High Level
Languages were produced.
Programming Languages
Learning Objectives:
- characteristics and purpose of
different levels of programming
language, including low-level
languages
- the purpose of translators
- the characteristics of an assembler, a
compiler and an interpreter
- common tools and facilities available High Level Languages (Python, Java, C++ etc)
in an integrated development
environment (IDE):
o editors High level code (aka ‘source code’) is far more easy to write
o error diagnostics
o run-time environment and therefore for humans to understand.
o translators.
.
GCSE 9-1: OCR Computer Science
Translators of Languages
So how does our ‘HUMAN WRITTEN
CODE’ get turned into Machine Code?
GCSE 9-1: OCR Computer Science
2 - Learning Objectives
Programming Languages
Learning Objectives:
- characteristics and purpose of Introducing Translators
different levels of programming
language, including low-level
languages So how does our ‘HUMAN WRITTEN CODE’ get
- the purpose of translators
- the characteristics of an assembler, a
turned into Machine Code?
compiler and an interpreter
- common tools and facilities available
Translators!
in an integrated development
environment (IDE):
o editors
o error diagnostics
High Level Language
o run-time environment
?
o translators.
Assembly Language
Hardware (CPU)
GCSE 9-1: OCR Computer Science
Programming Languages
Learning Objectives:
- characteristics and purpose of
Translators
different levels of programming
language, including low-level
languages
Translators are programs that convert high level language
- the purpose of translators commands:
- the characteristics of an assembler, a
compiler and an interpreter print, IF, For etc.
- common tools and facilities available
in an integrated development
…into a set of machine code commands:
environment (IDE): 1011, 11001, 11000011110 etc
o editors
o error diagnostics …so that the CPU can process the data!
o run-time environment
o translators.
There are 2 ways in which translators work:
Programming Languages
Learning Objectives:
- characteristics and purpose of
Types of Translator
different levels of programming
language, including low-level There are 3 types of translator:
languages
- the purpose of translators
- the characteristics of an assembler, a Compiler Interpreter Assembler
compiler and an interpreter
- common tools and facilities available Converts the whole code Converts the source code This type of translator is
in an integrated development into one file (often a .exe into machine code 1 line at a used for Assembly
environment (IDE): file). time. Language (not High Level
o editors Languages).
o error diagnostics The file can then be run on Program therefore runs very
o run-time environment any computer without the slowly. It converts mnemonic
o translators. translator needing to be assembly language
present. Main reason why an instructions into machine
interpreter is used is at the code.
Can take a long time to testing / development stage.
compile source code as the
translator will often have to Programmers can quickly
convert the instructions into identify errors and fix them.
various sets of machine
code as different CPUs will The translator must be
understand instructions with present on the computer for
different machine code from the program is to be run
one another.
GCSE 9-1: OCR Computer Science
Facilities of Languages
What do the programming languages have
to help us code?
GCSE 9-1: OCR Computer Science
3 - Learning Objectives
To be able to describe the common tools and facilities in an Integrated Development Environment (IDE)
GCSE 9-1: OCR Computer Science
Programming Languages
Learning Objectives: Integrated Development Environment (IDE)
- characteristics and purpose of
different levels of programming
language, including low-level
languages • An Integrated Development Environment (IDE) is a
- the purpose of translators
- the characteristics of an assembler, a software package.
compiler and an interpreter • It provides the tools for a computer programmer to
- common tools and facilities available
in an integrated development develop a software.
environment (IDE):
o editors
• It allows programmers to write their high level code, test
o error diagnostics it and translate it.
o run-time environment
o translators.
GCSE 9-1: OCR Computer Science
Programming Languages
Learning Objectives: Integrated Development Environment (IDE)
- characteristics and purpose of
different levels of programming
language, including low-level • IDEs will be specific to a certain high level language (eg:
languages
- the purpose of translators PyScripter is built for Python).
- the characteristics of an assembler, a
compiler and an interpreter
• They will normally consist of:
- common tools and facilities available • Source Code Editor – allowing the writing and editing of
in an integrated development
environment (IDE): code
o editors • Automation Tools – automate tasks such as finishing off key
o error diagnostics
o run-time environment words and indenting on your behalf
o translators. • Error Diagnostics - Debugger – identifies logic and syntax
errors and shows where they are.
• Translators - Interpreter – allows source code to be
translated into machine code one line at a time for
testing
• Translators - Compiler – converts entire source code into
machine code so it can be run as its own individual program
file.
• Auto-Documentation – stores lists of variables, modules,
functions calls etc which are documented for other
programmers.
GCSE 9-1: OCR Computer Science
Key Words
• Debug
Low Level Language • Translator
High Level Language
Machine Code
• IDE
Compiler • Language Translator
Interpreter
Assembler
• Device Driver
Source Code
Object Code
Executable Code