140 likes | 309 Views
By the end of this lesson you should be able to. Explain the difference between high level code and machine code. Explain the need for translators to convert high level code to machine code. Describe the characteristics of an assembler, a compiler and an interpreter.
E N D
By the end of this lesson you should be able to... • Explain the difference between high level code and machine code. • Explain the need for translators to convert high level code to machine code. • Describe the characteristics of an assembler, a compiler and an interpreter. • Describe common tools and facilities available in an integrated development environment (IDE): editors, error diagnostics, run-time environments, translators, auto-documentation.
Important! • Write the date at the top of a new page at the start of every lesson • When you see the pen symbol, you must copy down what is on the board. • Your book will be checked regularly, it must be presentable. • When you see the book symbol with a page number, you should turn to that page in your text book. Page: 00
Machine Code • Machine code are instructions in binary used by the CPU, for example: 01100101. • Most programmers can’t remember machine code so they use memory aids called mnemonics. • So the command OUT is used in place of 1011, for example. Page: 157
High Level Code • High level code is a term given to programming languages you might have used before such as java and python, for example: Print (“Hello World”) End • If the programmer makes use of high level code or assembly level languages then a translator must be used.
Quick Question • Why do you think a translator is need? Think about what a CPU is made up of.
Translator • A translator, or interpreter, translates high level code into machine code. • The little man computer is an example of this in action. The screenshot shows mnemonics being translated into numeric values and assigned values within the computers memory. The next step would be conversion into binary for the CPU to process.
Task • At the bottom of page 159 copy down the table that discusses assembler, compiler and interpreter advantages and disadvantages. • With the people sitting near you discuss why assemblers, compliers and interpreters are needed.
Task – characteristics table • Complete the table below using your books (page 157)
Thank you Microsoft! • Thankfully programming has been made much easier by companies such as Microsoft who create IDEs such as Visual Studio. • IDE stands for integrated development environment. • IDEs can be very complex or basic but all offer features useful to a programmer.
High level code Common commands
Task- Common Tools of IDEs • With the people near you, using the textbook, define the following tools and facilities of IDEs. Write your answers down. • Editors • Error diagnostics • Run-time environments • Translators • Auto- documentation
Extension task • Use the Internet to find examples of IDEs, create a table of the benefits, features and limitations of the IDEs you have found.
Exam Questions • Describe the difference between a high-level language and an assembly language. • What are the advantages of compiling a program for commercial distribution? • What are the features of an IDE? • What are the advantages of writing in high-level code compared with machine code?