4.6 - Fundamentals of data representation Flashcards

1
Q

What are hardware and software and what is the relationship between them?

A

Hardware - the physical components that make up the computer

Software - programs that are run by the computer

Hardware needs software to run; software needs hardware to run on

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Define ‘system software’.

A

Software that runs and manages the computer’s hardware and application programs eg. operating systems, utility programs and translators

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Define ‘application software’ and outline the 3 types.

A

Software that allows the user to complete different tasks

Types:
General purpose
Special purpose
Bespoke

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is general purpose software?

A

Software that can be used for a variety of tasks e.g. word processors, presentation software

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is special-purpose software?

A

Software that can only be used for one particular task e.g. scientific calculator software - can only carry out calculations

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is bespoke software?

A

Software that is developed to meet the user’s specific requirements e.g. self-service touchscreen kiosks at fast food restaurants

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Define ‘operating system’.

A

A collection of programs that controls the operation of computer hardware

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What are the 5 functions of an operating system?

A

Processor management (processor scheduling) - determines the order in which processes will be executed, allowing for multi-tasking

Inputs, outputs, and interrupts (input/output device management) - ensures efficient communication with devices and manages functionality issues

Memory management - records how memory in the computer is divided and identified so that it is allocated efficiently between running processes

Secondary storage management - tracks where files and programs are stored, which parts are available for storage, and manages files and folders based on user permissions

Security - ensures that resources are protected from unauthorised access through the use of permissions and passwords

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are the 5 characteristics of low-level languages?

A

Machine-oriented/non-portable - defined by the processor they are designed to run

No built-in functions

Can access specific registers in the processor

A 1:1 relationship with processor instructions

Programs typically require less memory and execute faster than a high-level language program performing the same task

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Define ‘opcode’ and ‘operand’.

A

Opcode - part of the instruction that specifies which operation the processor should perform

Operand - contains a value, or set of values, relevant to the opcode; can be an actual piece of data, or a reference to the memory location of the data for the opcode to act on

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Define ‘immediate addressing’ and ‘direct addressing’.

A

Immediate - operand interpreted as a data value (01)

Direct - operand interpreted as a memory address (10)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What are the 2 advantages of low-level languages?

A

Allows programmers to:
- Create optimised programs
- More directly control how resources are used when they are limited

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What are the 5 characteristics of high-level languages?

A

No 1:1 relationship with processor instructions - a single line of code can accomplish multiple tasks

Has to be translated into machine code for the computer to process

Offers development tools such as libraries and built-in functions

Problem-oriented rather thanmachine-oriented - typically designed to handle a particular problem

High levels of abstractions from the details of the computer - makes programming much more convenient and allows the programmer to write shorter, cleaner code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are the 3 advantages of high-level languages?

A

Mucheasierto write programs in them - they use normal command words such asIF, ELSE AND FOR, so it is much easier for a human to make sense of the program

Portable - can be compiled or translated to run on a wide range of computer architectures; they are not specific to a particular instruction set

Libraries of functions - can be imported and used by the programmer, allowing them to take advantage ofpre-written code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Define ‘imperative language’.

A

A language used to write a list of instructions to solve a problem, where the programmer defines how the problem should be solved

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Define ‘declarative language’.

A

A language used by the programmer to define what the problem to be solved is rather than how to solve the problem

17
Q

Define ‘object-oriented language’.

A

A language that programmers use to define objects and classes that define the data and the instructions to manipulate it

18
Q

How does a compiler translate code? (2 points)

A

Translates code into a form that can be executed but does not execute the code

Takes the source code as its set of instructions, which it then puts through a series of processes to produce executable code

19
Q

What are the 3 advantages of using a compiler?

A

Produces executable code in a form that cannot be read by a human or readily reverse-engineered - advantageous to commercial developers who make money from their code

When the program has successfully compiled, the executable file will not need to be translated again (unless the source code is changed) - faster running times

User doesn’t need a translator (i.e. interpreter) to be installed on their computer as they will never need to translate the program themselves

20
Q

What are the 2 disadvantages of using a compiler?

A

Any compilation errors are reported at the end of the compilation process

Compiled code can only be executedon a machine with the same processortype/instruction set

21
Q

How does an interpreter translate code? (2 points)

A

Each program line, when run, is syntax-checked - program halts and reports errors it finds

Each line of source code is converted into its machine code equivalent and executed

22
Q

What are the 3 advantages of using an interpreter?

A

Easier to debug during the testing stage of development - errors are reported and can be fixed when they occur

More portable - can be advantageous if the programmer does not know which platform will be used to run the code

Less memory than an executable file - only few lines of source code needed at any one time

23
Q

What are the 3 disadvantages of using an interpreter?

A

Source code that is interpreted runs more slowly than compiled code - each time the program is run, it must be translated all over again

User must have the interpreter installed to be able to run the program

Doesn’t protect the source code