

2.5.1.Languages
Presentation
•
Computers
•
10th - 11th Grade
•
Medium
Ian Currie
Used 1+ times
FREE Resource
19 Slides • 33 Questions
1
2.5.1.Languages
by Mr. Shingari
2
Walt
To be able to describe the different generations of programming language.
To be able to describe the differences between low-level and high-level languages.
To evaluate the benefits of programming in both low-level and high-level languages.
To state which translator is needed for each and why.
3
Open Ended
What would make code easier for a computer to understand?
What would make code easier for a programmer to write?
4
Open Ended
Find the error in this code:
The program should allow the user to input a value and then store it in memory address 25.
0001
1100
5
Error in task
0001 ‘This line is fine as it allows the user to enter a value into the Accumulator
1100 ‘This line of code is not valid as it does not specify the memory address
6
Open Ended
Find the error in this code:
The following program allows the user to enter a value – the number 3 is added to the value and then output. Another value is then entered and the number 1 is added to the value – this is then also output.
0001
1010 000011
0010
0001
1010 00000001
0001 00000001
7
Task 2
0001 ‘This is valid
1010 000011 ‘This is meant to add the value 3 – but the value is not an 8 bit Binary Number
0010 ‘This correctly outputs the contents of the Accumulator
0001 ‘This correctly allows input into the Accumulator
1010 00000001 ‘This correctly adds the value 1 to the contents of the Accumulator
0001 00000001 ‘This does not correctly output the contents of the Accumulator
8
Open Ended
Find the error in this code:
This program allows the user to enter 3 values – all the values are added together and output.
0001
1100 00010000
0001
0011 00010001
0001
1011 00010001
1010 00010000
0010
0001 00000001
9
Task 2
0001 ‘Correct – allows input into the Accumulator
1100 00010000 ‘Correctly stores the value in location 16
0001 ‘Correct – allows input into the Accumulator
0011 00010001 ‘Incorrect operation code
0001 ‘Correct – allows input into the Accumulator
1011 00010001 ‘Adds memory location 17 to the Accumulator
1010 00010000 ‘Adds the value 16 to the Accumulator
0010 ‘Outputs the result
10
Generations of programming languages
There are several generations of Programming Languages
Low-level
First generation
Second generation
High-level
Third generation
Fourth generation
11
First generation
Machine Code
Directly executable by the processor
The generation that ‘computers understand’
Difficult to program in, hard to understand, hard to find errors (hard to debug)
12
Wilf
You know the key features of Machine language.
13
Fill in the Blanks
Type answer...
14
Fill in the Blanks
Type answer...
15
Fill in the Blanks
Type answer...
16
Second generation
Assembly Code
Uses mnemonics
Easier to program but still difficult
One Assembly Language instruction translates to one Machine Code Instruction (1-1 relationship)
Needs to be translated into Machine Code for the computer to be able to execute it
It is most commonly used to program Device Drivers.
Device Drivers are loaded into memory by the Operating System and used to control the operation of a Hardware Device e.g. Graphics Card Drivers, Printer Drivers.
17
Fill in the Blanks
Type answer...
18
Wilf
You know the key features of Assembly language.
19
Fill in the Blanks
Type answer...
20
Fill in the Blanks
Type answer...
21
Fill in the Blanks
Type answer...
22
Fill in the Blanks
Type answer...
23
Fill in the Blanks
Type answer...
24
Wilf
You know the key features of High language and other languages.
25
Multiple Choice
Which language translator is needed for the first generation?
Compiler
Interpreter
No Translator
Language Translator
26
Fourth generations
Known as a Declarative Language
Facts and Rules are stated
Describes what computation should be performed and not how to perform it
Examples include:
SQL
Expert Systems
Artificial Intelligence
27
Multiple Choice
Identify the language this code belongs to?
Dim Num1, Num2, Tot as Integer
Num1 = Console.Readline()
Num2 = Console.Readline()
Tot = Num1 + Num2
Console.Writelein(“Total is: “ & Tot)
High-level (3rd Generation)
Low-level (2nd Generation)
Low-level
(1st Generation – Machine Code)
28
Third Generation
Easier to understand (programmer)
Easier to find errors, easier to de-bug
Uses English-Like Keywords
One instruction translates into many machine code instructions
e.g.’s Java, Basic, Pascal, C+
Translated using:
Compiler
Interpreter
29
Multiple Choice
Identify the language this code belongs to?
01010101010100101010100101010101010011111001000100001010100101
High-level (3rd Generation)
Low-level (2nd Generation)
Low-level
(1st Generation – Machine Code)
30
Multiple Choice
Identify the language this code belongs to?
LOAD r1, c
LOAD r2, d
ADD r1, r2
DIV r1, #2
High-level (3rd Generation)
Low-level (2nd Generation)
Low-level
(1st Generation – Machine Code)
31
Multiple Choice
Identify the language that has this feature.
Directly executable by CPU
Assembly language
Machine code
High level langauge
32
Multiple Choice
Identify the language that has this feature.
1-1 relationship between --------- Instruction and Machine Code
Assembly language
Machine code
High level langauge
33
Multiple Choice
Identify the language that has this feature.
Easier for programmer to understand,
de-bug and write
Assembly language
Machine code
High level langauge
34
Multiple Choice
Identify the language that has this feature.
1 to Many relationship in instructions with machine code.
Assembly language
Machine code
High level langauge
35
Multiple Choice
Identify the language that has this feature.
- Hard to understand
- Hard to De-Bug
Assembly language
Machine code
High level langauge
36
Walt
To be able to describe the differences in operation between a Compiler and Interpreter
37
Language translators
Language Translators are used to translate a language into a form that the will be able to directly execute
Compilers/Interpreters are used for 3rd Generation
38
Interpreters
Translate and execute source code.
Line by line, statement by statement.
Source code is checked for syntax – if correct, code is executed.
If incorrect interpreting is stopped.
Used for development (aid debugging).
39
Compilers
Translate entire source code all in one go into Machine Code.
Optimise code.
Used at the end of development (ready for shipping).
Error Reports created along with Object Code.
40
Multiple Choice
Translation software needed at run-time
Language Translator
Compiler
Interpreter
41
Multiple Choice
Translation software needed at run-time
Language Translator
Compiler
Interpreter
42
Multiple Choice
Translates entire source code in one go
Language Translator
Compiler
Interpreter
43
Multiple Choice
Which translator converts from different languages?
Language Translator
Compiler
Interpreter
44
Multiple Choice
Which translator is used at the end of development?
Language Translator
Compiler
Interpreter
45
Multiple Choice
Which language translator is used during the development of a program?
Code Translation
Compiler
Interpreter
46
Multiple Choice
Which language translator is used during the development of a program?
Code Translation
Compiler
Interpreter
47
Multiple Choice
Which language translator produces Object Code and an Error Report?
Code Translation
Compiler
Interpreter
48
Multiple Choice
Which language translator does not convert source code into machine code?
Code Translation
Compiler
Interpreter
49
Multiple Choice
Which language translator does not convert source code into machine code?
Code Translation
Compiler
Interpreter
50
Multiple Choice
What is meant by source code?
The final executable program
The code written by the programmer
The additional information about errors
Code relating to sources of information on the Internet
51
Walt
To be able to describe the common tools and facilities in an Integrated Development Environment (IDE).
52
Integrated Development Environment (IDE):
Editor (for writing the code)
Error Diagnostics (such as de-bug facilities)
Run-Time Environment
Translators
2.5.1.Languages
by Mr. Shingari
Show answer
Auto Play
Slide 1 / 52
SLIDE
Similar Resources on Wayground
47 questions
Electricity & Magnetism Review
Presentation
•
10th - 12th Grade
47 questions
Systems of Linear Equations: Solve by Graph and Substitution
Presentation
•
9th - 11th Grade
47 questions
Polynomials-Characteristics and Operations
Presentation
•
9th - 11th Grade
46 questions
Activity 5.1: Characteristics of Quadratic Graphs
Presentation
•
9th - 11th Grade
46 questions
Unit 5 - Internal Components
Presentation
•
9th - 12th Grade
44 questions
How to Improve Your Essay in CEFR-aligned SPM Writing Part 2
Presentation
•
10th - 11th Grade
45 questions
CompuScholar Chapter 3 Discussion
Presentation
•
9th - 12th Grade
45 questions
3-1 Inequalities and Their Graphs
Presentation
•
10th Grade
Popular Resources on Wayground
24 questions
PBIS-HGMS Day 10
Quiz
•
6th - 8th Grade
10 questions
HCS SCI 03 Summer School Review 3
Quiz
•
3rd Grade
11 questions
Home Scope
Quiz
•
7th - 8th Grade
15 questions
HCS SCI 05 Summer School Assessment 3 Review
Quiz
•
5th Grade
35 questions
Lufkin Road Middle School Student Handbook & Policies Assessment
Quiz
•
7th Grade
18 questions
Geo 11.3 Area of Circles and Sectors
Quiz
•
9th - 11th Grade