Presentation is loading. Please wait.

Presentation is loading. Please wait.

Intermediate 2 Computing Unit 2 - Software Development Topic 2 - Software Development Languages and Environments.

Similar presentations


Presentation on theme: "Intermediate 2 Computing Unit 2 - Software Development Topic 2 - Software Development Languages and Environments."— Presentation transcript:

1 Intermediate 2 Computing Unit 2 - Software Development Topic 2 - Software Development Languages and Environments

2 Describe and compare Machine Code and High Level Languages TOPIC 2 - SOFTWARE DEVELOPMENT LANGUAGES AND ENVIRONMENTS

3 Machine Code Processors only understand binary. Instructions and commands in binary are know as Machine Codes. Here are some machine codes: –010000011100110010100101 –011100001000011000011000 Are these easy to understand?

4 Machine Code Advantages of Machine Code. –Does not have to be translated into binary. Disadvantages machine code: –Very hard for humans to understand; –Take up a lot of space to write down; –Difficult to debug; & –Different processors use different machine codes. Machine codes are examples of Low Level Languages because they could only be understood by low level components.

5 High Level Languages High level languages (HLL’s) are similar to human languages. Instead of using binary patterns, they use “normal” words. Example: »ASK “Please enter your name” »PUT IT INTO varName –Although this is not correct English in terms of grammer and punctuation. With a little bit of an explanation we can understand it.

6 High Level Languages Advantages of HLL’s –High level languages are easier to understand than machine code, and are more ”readable”. –It is easier to find mistakes using HLL’s. Disadvantages of HLL’s –HLL’s must be translated into machine code so that the processor can understand the instructions. This can slow down the running of the program, & This can use more hardware resources to store the program, the HLL program, the translator and the machine code.

7 High Level Languages Advantages of HLL’s –High level languages are easier to understand than machine code, and are more ”readable”. –It is easier to find mistakes using HLL’s. Disadvantages of HLL’s –HLL’s must be translated into machine code so that the processor can understand the instructions. This can slow down the running of the program, & This can use more hardware resources to store the program, the HLL program, the translator and the machine code.

8 Explain the need for translation Topic 2 : Software development languages and environments

9 Translators Processors do not understand HLL’s. Translators have been developed to allow programmers to write programs in HLL’s and the translators will convert these programs into machine code. HLL CodeTranslatorMachine Code

10 Describe the functions of Interpreters and compilers Topic 2 : Software development languages and environments

11 Translators There are two main types of translators: –Interpreters; & –Compilers. Although both of these utilities do the same task (convert HLL to machine code) they both work differently.

12 Interpreters The interpreter takes each line of code, translates it into machine code and passes it to the processor to carry out the instruction. It works its way through the program one line at a time. Think of a spell checker in MS-Word. When you finish writing the work the dictionary checks it and if it is spelt incorrectly it will be underlined immediately.

13 Interpreters Advantages –Any errors that are found are highlighted as soon as the line is written showing exactly where the error is. Disadvantages –This slows the program down. –The interpreter runs every time the program is run. This is a waste of resources

14 Compilers A compiler takes your HLL program and translates the whole program into machine code. Any errors are reported in a batch once all the lines of code have been translated. The machine code version of the program can be kept and run as many times as needed without needing the original HLL version or the translator program.

15 Compilers Advantages –Running the machine code version of the program is very fast; –Running the machine code version does not waste computer resources. Disadvantages –Harder to find and edit mistakes when given in a batch; –Running a compiler is time-consuming.

16 Describe a macro, and examples of the use of macros Topic 2 : Software development languages and environments

17 Macros A macro is a program written in a scripting language and used with an application program. A macro is used to perform a perhaps complicated task simply by activating a key stroke. They automate tasks within the application package.

18 Macros Examples of when you would use a macro: –If you wanted to repeatedly search and sort a database using the same conditions it would be easier and quicker to use a macro. –If you wanted to repeatedly do a mail merge again it would be easier to use a macro. –If I wanted to change all the headings in this slide to Comic Sans instead of Jokerman I could use a macro instead of having to manually change each page.

19 Describe the features and use of a text editor Topic 2 : Software development languages and environments

20 Text Editors During the implementation stage the programmer codes the program. The HLL used looks like a human language. –This language is called the source code. Some software development environments provide a text editor. –This is where the source code is typed and edited. –It contains many features usually found in a word processor: Spell check Find/Change copy (Cut) / Paste. etc


Download ppt "Intermediate 2 Computing Unit 2 - Software Development Topic 2 - Software Development Languages and Environments."

Similar presentations


Ads by Google