Revision notes AQA Flashcards

1
Q

1 In mathematics which of the following are integers:
8 5 103 –1.33 1¾ 98 3.14 1500.45 –935 (7 marks)

A

8 5 103 98 –935

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

What is a real data type?

A

A real data type contains numeric data in a decimal form. It is used in
situations where more accurate information is required than an integer
(a whole number) can provide.

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

Give two reasons why a programmer would wish to use an integer
data type rather than a real data type.

A

Storage: Real data takes up more memory than integer data; The
number has decimals.

Processing speed: Calculations using real numbers takes longer than
using whole numbers held as integers.

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

Consider the following sentence and write it as a Boolean: (4 marks)
When the door is open and it is cold outside I have to wear my coat.

A

If (“door is open”) AND (“is cold outside”) then “wear coat”
or
If door=1 AND cold=1 then coat

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

In programming what is a ‘string’?

A

A string, or text, data type is capable of holding any alphanumeric
character (letters, numbers or symbols)
. It is also capable of storing
non-printable characters, such as carriage returns, punctuation
characters and spaces
. The data within a string data type can consist of
a combination of letters, numbers and symbols.

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

What is a ‘variable’ in programming? (1 mark)

A

Variables are data entities whose values can be altered when a program
is compiled
. As their name implies, their values vary.

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

What does the following code do? (3 marks)
If (($wet && $cold) || ($poor && $hungry)) {
Print “I’m sad!”;
}

A

The ‘print’ statement is executed if wet AND cold are both true OR if
poor AND hungry are both true.

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

What is the study of data structures about? (1 mark)

A

The study of data structures is about organising data so that it is
suitable for computer processing.

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

Explain the term ‘concurrent’.

A

‘Concurrent’ means happening at the same time as something else.

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

Explain, using an example, the term ‘one-dimensional array’.

A

A one-dimensional array is a list of variables. To create an array, you must
first define an array variable of the desired type. One-dimensional arrays
in Python and PHP allow a list of items to be stored with the capability of
accessing each item by pointing to its location within the array
, for example:
carMakers = [“Ford”, “Land Rover”,
“Vauxhall”, “Nissan”, “Toyota”]
or
<?php $carMakers = array[Ford, Land Rover,<br></br>Vauxhall, Nissan, Toyota]; ?>

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

Explain the difference between one- and two-dimensional arrays. (2 marks)

A

Two-dimensional arrays are nothing more than an array of arrays, in
other words an array in one row and another in the next row.

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

Why is the first element in an array usually [0] not [1]? (2 marks)

A

It is common practice within programming for the first element
within an array to be given an index of zero rather than 1, because
0 is considered by most mathematicians to be a real number
between –1 and 1
and so in languages wherearrays are positively
indexed, zero is the first number
(negative indexes are not possible).

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

Look at the following array.
carMakers = [“Ford”, “Land Rover”, “Vauxhall”,
“Nissan”, “Toyota”]
Use a coded solution to identify ‘Toyota’ as the car_name. (2 marks)

A

<?php <br></br> $car_name = carMakers[4];
?>

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

Program Flow Control

Explain with simple examples the basic building blocks of coded solutions. (3 marks)

A

The basic building blocks are: sequence, selection and looping.

  • Sequence example: Set, Input, and Output statements
  • Selection example: Conditional, if and if–else statements
  • Looping example: Iteration, While and Do–While statements
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Represent the following code as a simple flowchart. (4 marks)
if condition is true
then
perform instructions in Block1
else
perform instructions in Block2
endif

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

Design a simple flowchart to show the actions of a single move in a snakes
and ladders game.

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

What is the purpose of procedures and functions in programming
languages?

A

Procedures and functions allow the repetition of certain sections of a
program or calculation many times.
They also assist in themodulation
of code
by allowing themselves to be called from any point within a
program solution.

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

What is the main difference between a procedure and a function?

(2 marks)

A

A function carries out actions and returns a value to the main
program
. A procedurecarries out actions without returning a value.

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

scope of variables, constant, functions, and procedure

What is global scope?

A

A variable that can be accessed from anywhere within the project that
contains its declaration as well as from other projects that refer to that
initial project.

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

In terms of scope, briefly describe what is meant by: (2 marks)

a) local variable
b) global variable.

A

The scope of a local variable is the procedure in which it is declared.
The scope of a global variable is the whole program.

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

What are the three types of error that computer programmers encounter
when writing software? (3 marks)

A
  • Syntax errors
  • Run-time errors
  • Logic errors
22
Q

What is meant by a ‘format error’ and what is its correct name? (4 marks)

A

The correct name is ‘syntax error’ and it relates to the grammar rules of
the programming language used. These errors are usually due to using the
wrong case, placing punctuation in positions where it should not exist or
failing to insert punctuation where it should be placed within the code.

23
Q

State what happens when programming statements are written
in the wrong order and state the name for this type of error. (3 marks)

A

Called ‘run-time errors’, these errors occur when the program instructs
the computer to carry out an operation that it is either not designed
to do or slow to do. It causes a crash or slow running of the code.

24
Q

Which type of programming error is the hardest to detect and why? (3 marks)

A

Logic errors are the most difficult kind of errors to detect and rectify.
The program runs successfully but produces incorrect results.

25
What is the name given to the testing of software at the planning and flowchart stage? (2 marks)
Dry-run testing is usually carried out on the algorithm, written in pseudo-code or as part of a flowchart and before the program code is written.
26
What is a **‘trace table’**? (2 marks)
A **‘trace table’** is a technique used to test an algorithm to see if logic errors occur while it is being processed. Each column contains a variable and each row displays the numerical inputs into the algorithm and the resultant values of the variables.
27
What is correcting errors in a program called? (1 mark) a) compiling b) debugging c) grinding d) interpreting.
b
28
State the **four essential parts of a computer system.** (4 marks)
Input, output, process and storage.
29
Name three input devices. (3 marks)
Any 3 of: a keyboard, a mouse, a scanner, a microphone.
30
State three output devices. (3 marks)
Monitor, speakers, printer.
31
Explain the term **computer redundancy**. (4 marks)
Computer systems will break down eventually and so there is a need for strategies to deal with this. With regard to computer systems the method that is used is called ‘redundancy’. **Redundancy is a method of breakdown prevention where important parts of a system are duplicated** so that in the event of a failure the other components can take its place.
32
What is a CPU? (2 marks)
This internal device is often referred to as the ‘**computer’s brain**’ and it is the piece of hardware that is responsible for the ‘compute’ in computer.
33
Why should a CPU **not be referred to simply as the processor**? (2 marks)
‘Processor’ is a more generic term. There will be other processors in a computing system but only one CPU.
34
What does VGA mean? (1 mark) a) video graphics array b) visual graphics array c) volatile graphics array d) video graphics adapter
a
35
What is a **motherboard** and why is **bus speed important**? (4 marks)
The motherboard is like your **nervous system** – it provides the **essential connections that send and receive signals t**hroughout the system. The bus speed defines how much data the motherboard bus can handle at any one time; the more data, the faster the system.
36
CPU stands for: (1 mark) a) computer processing unit b) central processing unit c) computer protection unit d) central processing uploader
b
37
What is the difference between **volatile and non-volatile** memory? (2 marks)
Non-volatile memory is memory that retains its information when the power is turned off; volatile memory loses everything if it has no power.
38
What is cache memory? (3 marks)
Cache memory is the memory closest to the CPU. All the recent instructions are stored in cache memory as it is very fast. A cache memory often has an access time of 100ns, while main memory may have an access time of 700ns. Cache memory is very expensive and hence is limited in capacity.
39
Name the main two types of random access memory (RAM) and state what RAM is.
The two types of RAM are DRAM (Dynamic Random Access Memory); SRAM (Static Random Access Memory). RAM is a type of computer memory that can be accessed randomly (any byte of memory can be accessed without touching the preceding bytes); RAM is the most common type of memory found in computers and other devices, such as printers.
40
The maximum size of main memory of a computer is determined by the: (1 mark) a) operating system b) address bus c) data bus d) chipset.
b
41
Describe the difference between **secondary storage and main memory**. (6 marks)
Main memory is sometimes called RAM. It is directly connected to a processor and has fast access times. It also has a smaller capacity than storage devices and costs more per storage unit (i.e. byte). Secondary storage devices come in many forms including hard drives, USB flash drives, CD/DVD drives and tape drives. These devices are connected to the computer via an internal I/O port and have slower access times than to RAM. In addition, these devices are designed to have much larger capacities for data and the cost per storage unit is very low.
42
Where do your documents exist when you are working on them in a standard software application? (2 marks)
Main memory is where your documents exist while you are working on them. When you save, they are stored on a secondary storage device.
43
Briefly describe the term ‘algorithm’.
An algorithm in programming is a step-by-step process that solves a problem in code.
44
How can algorithms be represented? (1 mark)
An algorithm can be represented by code or by flowcharts.
45
Write an algorithm that can find the maximum of N values entered into a computer. (6 marks)
Input num[1], num[2], num[3], ..., num[N] Set Max = num[1] Set index = 2 While index \<= N Do If num[index] \> Max Set Max = num[index] Increment index End While Output Max
46
Write an algorithm that can find the sum and product of N values. (6 marks)
Input num[1], num[2], num[3], ..., num[N] Set Max = num[1] Set index = 2 While index \<= N Do If num[index] \> Max Set Max = num[index] Increment index End While Output Max
47
1 kilobyte refers to: (1 mark) a) 1000 bytes b) 1024 bytes c) 8000 bytes d) 8192 bytes
b
48
Give the four main differences between low-level and high-level programming. (4 marks)
High-level languages: ●● have more abstractions than lower level languages ●● are either compiled or interpreted but low-level languages do not need this type of processing ●● are more human readable than low-level languages. Low-level languages are more efficient than high-level languages.
49
Convert the denary number 1792 to binary. (1 mark)
11100000000 To do the conversion, we repeatedly divide by 2:
50
What meat do you get if you convert the denary number 48879 to hexadecimal? (2 marks)
BEEF To do the conversion, we repeatedly divide by 16:
51