Intermediate 2 Software Development Revision 2 Languages & Environments

waisttherapeuticΛογισμικό & κατασκευή λογ/κού

4 Νοε 2013 (πριν από 3 χρόνια και 9 μήνες)

43 εμφανίσεις

Intermediate 2


Software Development

Revision 2


Languages & Enviro
nments



1

At the end of this section you should be able to understand all of the statements shown below. Once
you are sure you understand a statement, then put a tick in the column beside it


Statement

Pupil
Assessment

Machine Code and High Level Languages


Comput
ers
only

understand machine code


Machine code is made up of binary digits (zeros and ones)


Machine codes are examples of
low level languages


Assembler

is another example of a low level language


Problems with machine code:



Different machine codes ar
e required for different processors



They are hard for humans to understand and use



They take up a lot of space to write down



It is difficult to spot errors in the codes


To overcome these difficulties
High Level Languages

were introduced


High Level lan
guages use English words


Examples of High Level languages are: Cobol, Pascal, Visual Basic, Java


High level languages are:



Easier to understand than machine code



More readable



Easier to spot and correct errors


Translation


As processors do not un
derstand High Level Languages, they have to be converted
into machine code


There are 2 types of translator programs: Interpreter and Compiler


Interpreters
: takes each line of High Level Language code and translates it into
machine code as the program
is being run


Disadvantage of Interpreters:



the process of translating the High Level Language (HLL) program slows
down the running of the program



The HLL program needs to be translated every time it is executed



Wasteful of resources (must have both HLL
program and Interpreter
program in memory)


Compilers
: take the High Level Language program and translates the whole program
into machine code once. This machine code can then be saved and kept


Advantages of Compilers
:



Once translated it can be used o
ver and over again without needing to be
translated every time



The compiled program therefore runs more quickly



Translator does not need to be kept on the computer therefore taking up
less memory


Example
: when you buy a computer game, it is the compil
ed code (machine code)
that you will have on the CD to install




Intermediate 2


Software Development

Revision 2


Languages & Enviro
nments



2

Text Editors


High Level Language programs
are very similar to English


therefore their
implementation is carried out using similar tools to those required for writing a
report


Some so
ftware development environments provide a text editor which incorporates
many of the usual features of a word processor (i.e.) cut/copy/paste


Macros


A

Macro
is a program


Macros are used to
automate a process

(either a repetitive task or a complicate
d
task)


Macros are written in a
scripting language
(i.e.) VBA


V
isual
B
asic for
A
pplications


Macros are a set of commands activated by a
single keystroke
or a

combination of
keys


Macros are for
repeated use


Macros
cannot exist alone



they only w
ork within an application program (i.e.)
Word, Excel,


Typical uses:



For automating a complex set of formatting commands in a word processor



Automating a complex query in a database