Font size
WorksheetsA2 EXTRA CS mmd
Total questions: 169
Worksheet time: 2hrs 1mins
Consider the following sequence of micro-operations.
MBR ← PC
MAR ← X
PC ← Y
Memory ← MBR
Which one of the following is a possible operation performed by this sequence?
Instruction fetch
Operand fetch
Conditional branch
Initiation of interrupt service
What are the main features of an operating system?
Provides interface for users to interact with the computer
Makes sure that all the parts of a computer work together
Manages memory
Swaps pages between memory and backing store
Translates program from assembly language into machine code
What are the purposes of scheduling?
Make efficient use of processor time
Make efficient use of resources
Maximise the number of users
Make efficient use of Binary
Allow programs to run that need more memory
How is virtual memory used?
Uses paging/fixed size units
Holds part of program not in use
Uses first come first served
If next user needs processor, user given time to slice
it is used to store data in the cloud
What is 6.625 in fixed point binary (4 bits for the whole number / 4 bits for fractional part)?
01101010
10001010
01101100
10001100
What is 0.125 in fixed point binary (4 bits for the whole number / 4 bits for fractional part)?
10001000
00000010
00001000
00011000
What is 5.5625 in fixed point binary (4 bits for the whole number / 4 bits for fractional part)?
01011101
01111001
01011100
01011001
Convert 11011.1001 to denary.
27.8125
27.5625
31.5625
31.34375
Which is NOT a disadvantage of fixed point binary numbers?
cannot represent the range of numbers
cannot represent the accuracy of numbers
easier to process
In floating point binary, it holds the detail of the number.
Mantissa
Exponent
In floating point binary, it holds the multiplier.
Mantissa
Exponent
010110100011 (8 bit signed mantissa / 4 bit signed exponent) what is the decimal number?
5.625
11.5
-5.625
-11.5
100101000011 (8 bit signed mantissa / 4 bit signed exponent) what is the decimal number?
9.25
-9.25
-6.75
6.75
011000001110 (8 bit signed mantissa / 4 bit signed exponent) what is the decimal number?
0.1875
-0.1875
96
-96
Why do we carry out normalisation on floating point binary numbers?
To convert the number into a negative number
To round a decimal number down
To provide the maximum level of precision
To round a decimal number up
What is the two's complement of 01100010 ?
10011101
11011101
10011110
10011111
In normalised floating point form, a positive number always has what beginning?
01
10
In normalised floating point form, a negative number always has what beginning?
01
10
What is the normalised form of 0.0000111 0111
1.0110000 0011
1.0110000 0111
0.1110000 0111
0.1110000 0011
What is the normalised form of 1.1100011 0011 ?
1.0001100 0001
1.0001100 0011
0.1001100 0001
0.1001100 0011
Convert 88 to normalised floating point binary.
0.1011000 0101
1.0011000 0111
0.1011000 0111
0.1011000 0110
Add 0.1100000 0001 and 0.1111100 0011 and normalise the result.
1001.0100 0100
0.1001010 0100
1.0010100 0100
0.1010100 0111
Subtract 0.1110000 0011 from 0.1101000 0100 and normalise the result.
0.1100000 0011
1.0100000 0011
0.1100000 0111
1.0100000 0111
Subtract 0.1011000 0011 from 0.1100100 0010 and normalise the result.
1.0110100 0010
0.1110100 0010
0.1101000 0010
1.0110100 1000
The Binary Integer 01001101 is represented in Denary as:
73
75
77
79
5.23 would be stored as:
Integer
Real Number
String
Character
Boolean
What is the binary number 0111 1101 in hexadecimal?
AC
9C
9D
8B
What is the Hexadecimal number 7C in denary?
83
123
141
124
What is an integer?
A number
A positive number
A whole number
A number with a decimal part
Which of these is a floating point number?
3
3.0
7
5.6
Which of these cannot be accurately stored as a floating point number?
1/8
2/3
4.00000000000000000001
4/4
17/9
Which one of these binary numbers is the normalised form of 6.5?
6.5 = 00000110.1
0.1011 0011
0.1101 0011
1.1001 0010
1.1010 1010
Convert 0x7A into binary
0b0111 1010
0b1001 1010
0b0101 1111
0b0111 1011
Convert 0b01010001 into denary
101
127
81
57
Add these two binary numbers together and convert into denary:
0.1011010 0110
+ 0.1110001 0111
156
157
158
Complete the following calculation, and leave it in normalized binary form:
0.1011010 0110
- 0.1110001 0111
1.0111100 0111
1.0111100 0110
0.1011110 0110
What does the number 10000001 represent when using two’s complement form?
1
-1
-127
-128
More information needed
How would -22 be represented with 6-bits in sign and magnitude form?
010110
110110
101010
10010110
101110
How many times more characters can Unicode (1 plane) represent compared to ASCII?
512
256
64
65536
What is the major advantage of using Unicode over ASCII?
It uses up more memory
It can represent more characters
It sounds much cooler
67
What is the value of 10011011 after 3 left shifts followed by 2 right shifts? Give answer in denary.
54
52
46
42
What value do you get when you use 00110001 as an XOR on the value 01101101?
01111100
01011100
01010110
01101101
X
X
X
X . X
X
is the same as
A . B
is the same as
A + B
A . B
is the same as
is the same as
A + B + C
A . B
A + B
A . B
( A + B ) ( C + D )
is the same as
AC + BD
(A . B ) + ( C . D )
A + B + C + D
AC + AD + BC + BD
Which of these are logic gates?
AND
OR
NOT
IF
ELSE
What is the output of an AND gate if its inputs are 1 and 1?
1
0
What is the output of an AND gate if its inputs are 1 and 0?
1
0
Which logic gate does this symbol represent?
AND
OR
NOT
IF
ELSE
What is the output Y of this logic cricuit if A = 1, B = 1, and C = 1
0
1
What is the output Z of this logic cricuit if A = 1 and B = 1
0
1
Which property: A+B = B+A or A * B = B*A
Associative
Distributive
Commutative
Bermuda Triangle
Which property: (A + B) + C = A + (B + C) or (A * B) * C = A * (B * C)
Commutative Property
Associative Property
Distributive Property
Not your property
A * (B + C) = A* B + A * C
Commutative Property
Associative Property
Distributive Property
No one's property
Who wrote this law: ~ (A + B) = ~A * ~B
Boole
Euler
DeMorgan
Wolfertz
Which law says 'Break the line, change the sign'?
De Morgans
Association
Commutative
Distirbutative
This law allows for the removal of brackets from an expression and the regrouping of variables
DeMorgans
Associative
Commutative
Distributative
This declares you can multiply or factor out an expression which is what you do in ordinary algebra
De Morgans
Distributive
Associative
Commutative
This law states that the order of application of two separate terms is not important
De Morgans
Commutative
Distributive
Associative
What rules have to be followed for absorption to apply?
The operators inside and outside of the brackets must be different, The terms outside the brackets must also be inside the brackets
The operators inside and outside of the brackets must be the same, The terms outside the brackets must not be inside the brackets
Which law is this an example of:
A(B+C) = (A.B)+(A.C)
A+(B.C) = (A+B).(A+C)
Associative
Commutative
Absorption
Distributive
This is the OR version of which law?
AV(BVC) = (AVB)VC = AVBVC
Commutative
Associative
Distributive
De Morgans
This is an example of which law?
A.B = B.A
A+B = B+A
Commutative
Distributive
Absorption
Associative
What is double negation?
Multiplying by 2
If you reverse something twice you end up back where you started
A negative number
What are the key reasons for compressing data?
Less space needed for storage
Less time to transmit
Higher quality files
Reduced amount of processing power
Limited RAM
Lossless compression...
Is used when not all the information is needed
Is not as effective as lossy compression
Can fully regenerate the original file
Includes files such as .ZIP
Would be a sensible choice for a music download site
Lossy compression...
Permanently removes data from a file
Always leads to a noticeable loss of quality
Aims to remove redundant data
Can return the original file to its original quality
Would be a sensible choice for a music download site.`
Dictionary based compression...
Is a lossless compression format
Creates a dictionary of common letter combinations to encode words with fewer characters
Creates a dictionary of smaller letters so less space is used
Sends the dictionary with the data
Doesn't need to send the dictionary with the data
Run-length encoding...
is Lossless
is Lossy
Can only be used for text
Records the number of repeats of an individual element
Can be used for a wide variety of file types
Encryption...
Uses at least one key to cipher data
Is only used on text
Can be symmetric or asymmetric
Is impossible to break
Has developed a lot as processing power has increased
Symmetrical encryption techniques...
Are the most secure types of encryption
Use a single key to encode/decode
Use multiple keys to encode/decode
Include XOR, Caesar and Route
Include RSA, Diffie-Hellman and DSS
Asymmetrical encryption techniques...
Are the most secure types of encryption
Use a single key to encode/decode
Use multiple keys to encode/decode
Include XOR, Caesar and Route
Include RSA, Diffie-Hellman and DSS
Asymmetrical encryption...
Often requires considerable processing power
Is impossible to break
Is being threatened by the possibility of quantum computing
Can be brute-force attacked
Is very widely used, even in small businesses
What is the correct Run-length encoding for the data: cccmmmmmsssssdcccccc
3c5m5s1d6c
c3m5s5d1c6
cmsdc35516
cccmmmmmsssssdcccccc
Definition of encryption
Using an algorithm and a key to convert message data into a form that is not understandable without that key.
A method of trying to find the plain text from the cipher text without the decryption key.
Process of turning legible text into gobbledygook.
Using an algorithm and a key to convert encrypted message data into its plain text equivalent.
Definition of decryption
Using an algorithm and a key to convert message data into a form that is not understandable without that key.
A method of trying to find the plain text from the cipher text without the decryption key.
Process of turning legible text into gobbledygook.
Using an algorithm and a key to convert encrypted message data into its plain text equivalent.
A Caesar cipher encrypts the plaintext Et tu, Brute into the ciphertext ix xy, fvyxi. What would the same cipher encrypt it was Greek to me into?
mx aew kviio xs qi
ny bfx lwjjp yt rj
ep swo cnaag pk ia
qb eia ozmms bw um
Why are Caesar ciphers so easy to crack?
There are only 25 possible 'shifts', so a brute force attack will easily find the key required.
Use of frequency analysis will be able to find common letters and words.
Each key is only used once.
The number of shifts is calculated from the number of characters in the plaintext.
The Caesar cipher is an example of what type of cipher?
Substitution cipher
Transposition cipher
Public key encryption
Vernam cipher
What are the conditions required for a Vernam cipher to be 100% mathematically secure?
The key is used only once, and then destroyed/
The key is made up of truly random characters/
The key must be made up of fewer characters than the plaintext message.
Different keys must be used to encrypt and decrypt a message.
Which Boolean operator is used to produce the cipher text from the plaintext and the key?
XOR
NOR
OR
NAND
The letter m has an ascii code of 1101101. As part of a Vernam cipher, the key 0101001 is applied to that letter. What is the resulting ciphertext?
1000100
0111011
1100101
1101001
Which cipher is considered to be 100% mathematically secure?
Caesar cipher
Vernam cipher
Transposition cipher
Railfence cipher
If a cipher is theoretically possible to break, but not when using current technology in a timeframe that would be useful is known as what?
Computationally secure
Intractably resistant
Algorithmically impossible
Cryptographically unbreakable
Select the true statements about operating systems:
A computer can only have one OS
The OS manages memory, storage, security, printing and other useful functions of the system
The OS provides a user interface
All OSes allow you to use multiple programs at once
This image shows...
Memory paging
Memory segmentation
Distributed processing
Virtual memory
This image shows...
Memory paging
Memory segmentation
Distributed processing
Virtual memory
Select the true statements about memory paging:
Processes are split into equal sized frames
A page table is used to record all the pages
Unused pages are swapped out of main memory and into virtual memory
Processes are split into variable sized frames
Segmentation:
Splits processes into variable sized pieces
Splits processes into set sized pieces
Keeps processes together in RAM
Places processes wherever there is space in RAM
Can cause stack overflows
The role of scheduling is...
To make sure tasks get as much time as they need on the CPU
To make sure that all tasks get time on the processor and respond in a reasonable time
To make sure that the user does not have to wait for processes to run
To prevent the user from crashing the computer
An OS which you would use in day-to-day life on a normal school computer is a...
Embedded
Real Time
Distributed
Multi-Tasking
Multi-User
For a very large and complex system which needs multiple processors, you would use a _______________ OS:
Embedded
Real Time
Distributed
Multi-Tasking
Multi-User
For a system which needs a guaranteed response rate, you would use a _______________ OS:
Embedded
Real Time
Distributed
Multi-Tasking
Multi-User
For a simple system with very limited processing power, you would use a _______________ OS:
Embedded
Real Time
Distributed
Multi-Tasking
Multi-User
To share one processor's power between multiple people, you would use a _______________ OS:
Embedded
Real Time
Distributed
Multi-Tasking
Multi-User
The BIOS allows you to:
Change the computer's time/date settings
Change the order in which drives are booted from
Change the computer's operating system
Change the user's login details
Device drivers...
allow peripherals to communicate with the OS
allow users to communicate with the OS
allow peripherals to work directly with the CPU
allow users to change settings of their peripherals
A virtual machine...
uses secondary storage instead of RAM when the computer runs out of space on the main memory
allows software to act as hardware, running code or an operating system within another OS.
can only be used through the internet
relies on cloud storage
Select the real methodologies:
Agile
XP
XD
Spiral
Waterfall
Iterative development methodology which values end-user input:
XP
Agile
Waterfall
Spiral
RAD
Iterative development methodology which values code quality:
XP
Agile
Waterfall
Spiral
RAD
Iterative development methodology which values speed of development:
XP
Agile
Waterfall
Spiral
RAD
Iterative development methodology which focuses on risk-management:
XP
Agile
Waterfall
Spiral
RAD
Sequential development methodology which focuses on comprehensive documentation:
XP
Agile
Waterfall
Spiral
RAD
A small start-up who want to get a prototype onto the market for testing should use:
XP
Agile
Waterfall
Spiral
RAD
A large company who want to develop their software so people actually want to use it should use:
XP
Agile
Waterfall
Spiral
RAD
A processor company who need to develop high-quality code with minimal errors should use:
XP
Agile
Waterfall
Spiral
RAD
Most software companies use:
XP
Agile
Waterfall
Spiral
RAD
Very large projects which require a lot of paperwork and documentation should use:
XP
Agile
Waterfall
Spiral
RAD
A company who need to manage a lot of risk should use:
XP
Agile
Waterfall
Spiral
RAD
This methodology is:
XP
Agile
Waterfall
Spiral
RAD
This methodology is:
XP
Agile
Waterfall
Spiral
RAD
This methodology is:
XP
Agile
Waterfall
Spiral
RAD
This methodology is:
XP
Agile
Waterfall
Spiral
RAD
This methodology is:
XP
Agile
Waterfall
Spiral
RAD
Application Software is...
software designed for a specific task
software designed for general use
software such as Steam, Word and PowerPoint
software such as WinZIP, Norton AntiVirus and Windows Defender
Utility Software is...
software designed for a specific task
software designed for general use
software such as Steam, Word and PowerPoint
software such as WinZIP, Norton AntiVirus and Windows Defender
Open Source software is...
Always bug free
Usually well documented
Fully editable
Free to use
Definitely suitable for use by a large organisation
Closed Source software is...
Always bug free
Sometimes very expensive
Generally well-tested
A good choice for large organisations
Usually well-supported by the developer
Converts high-level code to low-level:
Interpreter
Compiler
Assembler
Creates an executable file
Interpreter
Compiler
Assembler
Must be installed for the code to run on another machine
Interpreter
Compiler
Assembler
Converts low level code to machine code
Interpreter
Compiler
Assembler
The correct order of the stages of compilation is:
Lexical Analysis, Syntax Analysis, Code Generation, Code Optimisation
Lexical Analysis, Syntax Analysis, Code Optimisation, Code Generation
Syntax Analysis, Lexical Analysis, Code Optimisation, Code Generation
Syntax Analysis, Lexical Analysis, Code Generation, Code Optimisation
Removing whitespace is in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
Token creation is in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
Symbol table is created in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
The code is checked against the rules in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
The syntax tree is created in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
The user will first be alerted to errors found in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
The syntax tree is converted into object code in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
Redundant code is removed in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
The code is improved to run as fast as possible in:
Lexical Analysis
Syntax Analysis
Code Generation
Code Optimisation
An entity is represented by what in a database?
Table
Row
Column
Cell
A record is represented by what in a database?
Table
Row
Column
Cell
An attribute is represented by what in a database?
Table
Row
Column
Cell
Which of these are required for a relational database to meet 1st normal form?
Data must be atomic
No repeating groups of data
No repeating attributes
Sets of data must have a unique identifier
Must meet 2nd normal form
Which of these are required for a relational database to meet 2nd normal form?
Must meet 1st normal form
All the non-key attributes must depend on the whole primary key
All the non-key attributes must not depend on another non-key attribute
Must meet 3rd normal form
Which of these are required for a relational database to meet 3rd normal form?
Must meet 2nd normal form
All the non-key attributes must depend on another non-key attribute
All the non-key attributes must not depend on another non-key attribute
Must meet 4th normal form
What is the purpose of normalisation?
Eliminate redundant data
Reduce data inconsistencies
Produce redundant data
Increase data inconsistencies
Which type of relationship does the ERD represent?
One-to-many
Many-to-many
One-to-one
Which type of relationship does the ERD represent?
One-to-many
Many-to-many
One-to-one
In a RDBMS such as MS Access, which type of relationship is required to create relationships between entities?
One-to-many
Many-to-many
One-to-one
Which keys are required to create relationships between entities?
Primary key and foreign key
Primary key and secondary key
Foreign key and domestic key
Secondary key and foreign key
What is a foreign key?
Uniquely identifies the records in a table
An attribute that is a primary key in another table
A record that meets 3rd normal form
A primary key made up from two or more attributes
What is a composite primary key?
A primary key that can be duplicated in the same table
An attribute that is a primary key in another table
A foreign key that is a primary key in more than one other table
A primary key made up from two or more attributes
Data type used for telephone numbers
Text
Number
Date/Time
Yes/No
Currency
A table where all attributes are dependent on the primary key and are independent of each other, and no row contains two or more multivalued facts about an entity, is said to be in ____.
1NF
2NF
3NF
4NF
What is the correct order of clauses in a SQL statement?
SELECT, FROM, ORDER BY, WHERE
SELECT, FROM, WHERE, ORDER BY
SELECT, WHERE, FROM, ORDER BY
WHERE, FROM, SELECT, ORDER BY
How do we select all rows for the "Designer" table?
SELECT * FROM Designer
SELECT [All] FROM Designer
SELECT Designer.*
SELECT FROM Designer
How would we script a SQL query to select "Description" from the Item table?
SELECT Item.Description
EXTRACT Description FROM Item
SELECT Item FROM Description
SELECT Description FROM Item
Which query would return only the fields DesignerID and Designer?
SELECT * FROM Designers
SELECT DesignerID, Name FROM Designers
SELECT DesignerID AND Designer FROM Designers
SELECT DesignerID, Designer FROM Designers
You are required to update the phone number for only the DesignerID "SMI01" in the "Designer" table. Which of these would successfully do that?
UPDATE Designer SET PhoneNo = '01224123456'
UPDATE Designer (PhoneNo) VALUES ('01224123456')
UPDATE Designer SET PhoneNo = '01224123456' WHERE DesignerID = 'SMI01'
UPDATE PhoneNo = '01224123456' FROM Designer WHERE DesignerID = 'SMI01'
With SQL how can I return all items in the Item table sorted from the lowest priced to the highest priced?
SELECT * FROM Items ORDER BY Price ASCENDING
SELECT * FROM Items ORDER BY Price ASC
SELECT * FROM Items BY Price LOWEST TO HIGHEST
SELECT * FROM Items ORDER BY Price DESC
How would you DELETE records from the Items table with a "Chair" Type?
DELETE 'Chair' FROM Items
DELETE Type FROM Items WHERE Type = 'Chair'
DELETE FROM Items WHERE Type = 'Chair'
DELETE ITEMS WHERE Type = 'Chair'
How would you display Chairs in the Items table that have a Price greater than £50.
SELECT * FROM Items WHERE Type = 'Chair' AND Price > 50
SELECT * FROM Items WHERE Type = 'Chair' OR Price < 100
SELECT * FROM Iterms WHERE Type = 'Chair' AND Price >= 50
SELECT * FROM Items WHERE Price > 50
Which SQL statement would add a record to the database?
INSERT INTO Designer VALUES ('SMI01', 'M Smith', 'mail@msmith.com', '01224123456')
INSERT VALUES ('SMI01', 'M Smith', 'mail@msmith.com', 01224123456') INTO Designer
INSERT ('SMI01', 'M Smith', 'mail@msmith.com', '01224123456') INTO Designer
INSERT Designer INTO VALUES (''SMI01', 'M Smith', 'mail@msmith.com', '01224123456')
