Incorrect Answers Flashcards
What is meant by problem recognition?
Identifying there is a problem to be solved and what the problem is.
What is a difference between a tree and a graph?
A graph has cycles.
A graph can be directed/undirected.
A graph can be weighted.
What are two advantages of visualisation?
Visualisations benefit humans rather than computers.
They present the information in a simpler form to understand.
They can best explain complex situations.
Describe how a 1D array can be set up and used to push and pop items as a stack. [4 marks]
The array size is defined.
A stack pointer is used to point to the top of the stack.
When an item is pushed to the stack, the pointer is incremented.
When an item is popped from the stack, the pointer is decremented.
Explain how a private attribute improves the integrity of data.
Properties can only be accessed through their methods.
So it cannot be changed accidentally.
How can a program be amended to make sure the items and queue still exist and are used the next time the program is run?
Store the items and queue to an external file.
Load the items and queue from the file when it starts.
Define the term ‘embedded operating system’.
System software which is built into the device itself.
It is stored in the device’s ROM.
Explain how a hash table can be used to handle collisions, referring to the example below. [4 marks]
Linear probing could be used. It moves through the structure one space at a time to find the next free space.
Chaining could be used. Each location points to the start of a linked list. The new item is added to the end of the linked list.
Describe what the effect would be of a computer having its BIOS overwritten. [2 marks]
The computer would not be able to boot/load the OS which would make the computer unusable.
What is a server?
A device which provides a central point of control.
Why is it important that the review score that the user entered is also checked server-side?
Client side processing can be modified and can sometimes be disabled on the browser.
To prevent malicious code such as an SQL injection.
To prevent a non-validated review being sent to the server.
Describe two ways in which the accumulator is used. [4 marks]
Temporary storage for data being processed during calculations.
It is also used as an I/O in the processor and is used as a buffer.
What happens to the PC when there is a ‘jump’ instruction?
The address in the CIR is sent to the PC.
Describe the role of the control unit in the processor. [2 marks]
Decodes instructions.
Sends control signals to coordinate the movement of data through the processor.
Describe one issue that the line ‘BRP start’ may cause for a CPU using pipelining. [2 marks]
BRP could be followed by one of two possible instructions, which one will only be determined at execution.
This means that the wrong instruction may be fetched and decoded.
What does pre-emptive mean?
Processes currently running can be suspended if a higher-priority item enters the queue.
Explain why memory management is necessary. [3 marks]
Organises the use of main memory by converting logical addresses to physical addresses.
It allows programs to share memory and protect data from each other.
It also allows programs larger than main memory to run.
State two similarities between paging and segmentation. [2 marks]
Both ways of partitioning memory.
Both use virtual memory to swap parts of programs.
Both allow programs larger than memory to run.
Explain why the first-come, first-served scheduling algorithm may not be efficient. [2 marks]
Once a job starts being processed, it stops other jobs from being processed.
A job using a slow resource (eg. a printer) wastes processor time.
Explain why a linker would need to be used after compilation. [3 marks]
The user running the program will not necessarily have the library installed on their machine. Therefore the relevant code needs to be included within this final executable. It is the job of the linker to provide this.
Describe what happens during syntax analysis when code is compiled. [5 marks]
The tokens are checked against the rules of the programming language.
The errors are reported as a list. Detail such as data type and scope is added to the symbol table.
It then passes the code to code generation.
What is the purpose of a linker?
Incorporates the code from the library with the main program into a single executable file.