Friday, 30 May 2014
Polling, Spooling and Interrupt in Operating System
Data Protection Act 1998
Personal data must be processed following these principles so that data are:
- processed fairly and lawfully
- obtained for specified and lawful purposes
- adequate, relevant and not excessive
- accurate and, where necessary, kept up-to-date
- not kept for longer than necessary
- processed in accordance with the subject's rights
- kept secure
- not transferred abroad without adequate protection
The Data Protection Act 1998 came into force on March 1 2000. The Act gives legal rights to individuals in respect of personal data held about them by others.
Under the Act, personal data must be processed following the Data Protection Principles so that data are:
- processed fairly and lawfully and only if certain conditions are met
- obtained for specified and lawful purposes
- adequate, relevant and not excessive
- accurate and where necessary kept up-to-date
- not be kept for longer than necessary
- processed in accordance with the rights of data subjects
- kept secure
- not be transferred abroad unless to countries with adequate data protection laws
You are entitled to have access to information held about you, except where releasing that information would breach another person's privacy. You also have rights including rights to prevent processing likely to cause unwarrented damage or distress and to prevent processing for the purposes of direct marketing.
Tackling the exam papers (Exemple candidate response)
Tackling the exam papers
General tips
Exemple candidate response
2 Data (Computer Science)
Data are the raw facts and figures that we give to a computer as input. Data lack sufficient context and processing to have meaning.
When data are processed to have context and meaning, and to search, sort and make calculations, they become known as 'information'.
Data may need preparation after collection and before they are used as an input, to ensure that they are in the correct format.
Data are encoded to summarise them, so that they are quicker to enter, with fewer errors, occupy less memory and backing storage, and are quicker to process.
Data sometimes need to be prepared so that they have a uniform format suitable for input into a computer.
An analogue input signal needs to be converted into digital data. This is done with an analogue-to-digital converter (ADC). This process is known as digitisation.
Digital output signals often need conversion to analogue signals in order to provide an output. This is done with a digital-to-analogue converter (DAC).
ADC and DAC devices can be found in a computer's sound card.
Data capture is when data actually enters the computer. This happens after data collection and data preparation. Data capture may be:
• Manual
• Automatic.
Inaccurate data are of little value, so their accuracy is checked by validation and verification.
Data validation
A validation check prevents the input of a data item if it is not sensible and reasonable. When this is the case, an error message is displayed. Types of validation check include:
• Type
• Range
• Limit
• Length
• Character
• Format Or Picture
• Presence
• Consistency
• Check Digit.
Data verification
Verification is a way of preventing errors when data is copied from one medium to another (e.g. from paper to disk/CD, from memory to DVD, etc.). There are a number of ways in which verification can be done:
Double entry in this method, data is entered twice (using two different people); the data is only accepted if both versions match up. Often used to verify passwords by asking them to be typed in again by the same person.
Visual check this is checking for errors by comparing entered data with the original document (NOTE: this is not the same as proof reading!!).
Parity check this is used to check data following potential transmission errors; an extra bit is added to each binary number before transmission – e.g. EVEN parity makes sure each number has an even number of 1 – bits;
Example: if 11000110 is sent (four 1's) and 11100110 is received (five 1's) then the system will know an error has occurred.
– a record is a set of data usually displayed in a row of a table:
– a data field holds a specific type of data about a characteristic of the items recorded, usually displayed in a column of a table
– a record key field holds a unique identifier for each record
– a set of records are stored together as a data file
• records within files can be organised in different ways:
Ø A Serial file: A File in which data is stored in the order in which it arrives.
Ø A Sequential file: A file in which data is stored in a sequence using a key field and can be read from beginning to end.
Ø A Direct access file: A file stores data in no particular order and is very useful because adding new data is very simple in it.
File maintenance is the processing of a file that is not part of routine transaction processing, or updating a main file using a transaction file. Maintenance involves:
• inserting a record, e.g. a new record for a new client
• deleting a record, e.g. removing the record of a client who ends their relationship with the organisation
• updating (amending or editing) a record, e.g. altering the record of a client who changes their address.
This usually involves rewriting the whole file for a sequential file, but not for a direct access file.
Different data types are identified so that a computer can store and process the data appropriately.
Data types include:
Ø string (or text)
Ø number (numeric):
o integer
o real (or decimal)
Ø currency
Ø date/time
Ø Boolean (or Yes/No).
Data structures are more complex data types, consisting of a number of data items of one or more data types. They include the record and array structures.
An array consists of a number of elements of a single data type. An array may have one or more dimensions. A program refers to an element using the array's identifier and an index number for each dimension. This approach enables efficient programs for filling an array, searching for a value in the array or generating output from its elements.
Controlled devices usually contain registers which are made up of binary digits (bits). The following example shows how these registers can be used to control a device.
(1 = ON and 0 = OFF)
Therefore, 1 0 1 0 1 0 1 0
means:
front wheel turns left
back wheels turn left
the direction is forward
the motors are on
therefore the trolley is moving forward and turning left.
(i) What does this register mean?
0 0 0 1 0 1 1 1 ?
(ii) How would the following be represented using the above register?
- front wheel turning right
- back wheels turning left
- moving in a forward direction
- motors on
- no object in its path
Answers
(i) - front wheel not turning left or right
- rear wheels turning right
- going in backward direction
- motors on
- error – object in path
So the vehicle is going nowhere.
(ii) 0 1 1 0 1 0 1 0
- An estate agent uses a computer system to store details about properties for sale. A section of the properties file is shown below:
- Why is coded data used for Type?
- What is the data type for Price?
- What is meant by a key field? Which is the key field?
- a What is meant by analogue data?
- When does analogue data need to be changed into digital data?
- What device performs the conversion?
- Give one application which would use analogue data.
- a What is meant by digital data?
- Give one application which would use digital data.
- Explain the following terms:
a. database
b. file
c. direct access file
d. record
e. sequential file.
- A shop sells bicycles. Information about each bicycle in stock is held in a computer file. Part of the information is shown in the table below.
a. How many fields are shown?
b. How many records are shown?
c. Give a reason why the shop would need to delete a record from the bicycle stock file.
d. Give a reason why the shop would need to add a record to the bicycle stock file.
e. Explain how the shop can print a list of mountain bikes.
f. There is an error in the table. Which item is wrong? How could this error have been avoided?
g. Which is the key field?
- A video club hires films to members. The club uses separate database files to store details about films, members and the films hired.
a. Name four suitable items of information for the FilmsHired database file, specify the field type and give an example of the data.
b. Name four suitable items of information for the Members database file, specify the field type and give an example of data.
- a What is meant by the term 'validation'?
- What is meant by the term 'verification'?
- Describe one method of verification when changing a password.
Below each answer there is a page reference for the coursebook. This is there to help you focus your revision. If you find that you get an answer wrong, you can use this guide to return to the coursebook to revise the areas that need some extra attention. Please note these are example answers only and do not represent the only possible answers.
2 A file is a collection of related data such as a set of data records. A record is a data structure that contains items of data about a thing in the real world. Each item of data within a record is known as a field.
3 a Coded data is used for Type because the full description would be longer. It would take up more storage space and may lead to errors in data entry.
b The data type for Price is real or decimal (numerical data type).
c A key field is an item of data that uniquely identifies a record. In this case, the key field is Property.
4 a Analogue data is data that changes continuously rather than in discrete jumps, for example, temperature or volume. It can be captured by a sensor.
b Analogue data need to be changed into digital data for it to be manipulated by a computer.
c An analogue-to-digital converter performs the conversion.
d A greenhouse control application would collect analogue temperature data and a computer would decide when to switch on and off a heater.
5 a Digital data is data that changes in discrete, or stepwise, jumps. For example, the number of bikes sold or a person's age.
b A utility billing application would use digital data from meter readings.
6 a A database is a set of tables that hold information about related things. (See page 8 or glossary.)
b A file is a set of data or program items held in a named area of storage (or a physical data structure).
c A direct access file is a file stored on disk. Its records can be accessed directly by using an algorithm to generate a record's disk address from the record's key value.
d A record is a set of data items about one type of thing.
e A sequential file is a file in which records are stored in order of their record key values.
7 a There are six fields (columns) shown. (See page 9 or glossary for definition of a 'field'.)
b There are seven records (rows) shown.
c The shop would need to delete a record when a bicycle is sold.
d The shop would need to add a record when a new bicycle is delivered from the supplier.
e The shop can print a list of mountain bikes by selecting all records where the Type = 'Mountain'.
f The price of stock number 1972 is incorrect. It could have been avoided by setting a limit or range.
g The key field is StockNo.
8 A video club hires films to members.
a Four suitable items of information for the FilmsHired file are:
b Four suitable items of information for the Members file are:
9 a The term 'validation' means examining input data to ensure that it falls within pre-set criteria. For example, a date of birth must be before a certain date to be valid for a pupil to be enrolled.
b The term 'verification' means double-checking that copied data is correct.
c One method of verification when changing a password is to ask the user to type it a second time, i.e. double entry.
A list of examination-based problems now follows. These can be used as revision questions or centres can use the questions to make up their own assessments to give candidates practice under examination conditions.
(1) Describe four methods used for automatic data capture. Give a different application for each of the methods chosen.
(2) A record contains the following fields:
- Title (Mr/Mrs/Miss) and Sex (Male or Female)
- Date of birth (written in the form dd/mm/yyyy)
- Pay Number (which is made up of 8 digits)
- Telephone Number
- Pay
Give a different validation check for each of the above fields and explain why it is used.
(3) A system uses the ISBN-10 (modulo 11) method to generate and validate bar codes:
- each digit in the number is multiplied by its digit position
- the result of each multiplication is added to a total
- the total is then divided by 11
- the remainder is subtracted from 11 to give the check digit (if the remainder is 10, the letter "X" is used as the check digit)
(a) Which of the following numbers have the correct check digit?
(i) 0 – 5 5 5 – 2 1 6 2 2 – 5
(ii) 0 – 1 2 1 – 9 0 0 2 1 – X
(b) Calculate the check digit for the following number:
0 – 1 5 0 – 2 4 6 2 2 – ………
(c) Discuss the types of errors that check digits can identify.
(4) (a) Describe three ways of carrying out verification checks.
(b) Give two examples where verification checks would be made.
(5) A burglar alarm system uses an 8 – bit register. The first 4 bits indicate if a sensor has picked up an intruder (shown with a 1 – value) and the second four bits indicate the zone where the sensor has picked up an intruder:
(b) What would be the binary pattern for a window broken and an infra red sensor detecting an intruder both in zone 15?
(6) A company is using a word processor to produce a page advertising their products. Unfortunately, the information wouldn't fit onto one single page.
Which five features of a word processor could be used to ensure that the advert fits onto one page only.
(7) A college has invested in a computer system to help carry out the following tasks:
- advertise their college (both on the Internet and by paper leaflets)
- keep a track of student and staff information/contact details
- keep a track of payments and fees
- produce on line courses for the students
Describe four software packages the college could use to carry out the above tasks and explain why each software package has been chosen.
(8) Describe three fundamental differences between word processors and desk top publishing packages.
(9) A database has been set up to compare certain features of freezers. A section of the database is shown below.
(a) How may records are shown in this section of the database?
(b) What items would be output if the following search condition was input:
(Price($) > 300 OR Warranty(years) > 1) AND (Colour = "silver") ?
(c) Give the search condition to find all freezers which operate below - 250C and have a capacity of more than 0.25 m3.
A digital alarm clock is controlled by a microprocessor. It uses the 24-hour clock system (i.e. 6 pm is 18:00). Each digit in a typical display is represented by a 4-digit binary code.
(c) The clock alarm has been set at 08:00.
Describe the actions of the microprocessor which enable the alarm to sound at 08:00. [2]
Marking:
(c) Any two from:
– microprocessor compares present time with stored time
– if the values are the same
– sends signal to sound alarm [2]
When a key is pressed on the keyboard, the computer stores the ASCII representation of the character typed into main memory. The ASCII representation for A is 65 (denary), for B is 66 (denary), etc.
There are two letters stored in the following memory locations:
(a) (i) Show the contents of Location 1 and Location 2 as binary.
Location 1, Location 2 [2]
(ii) Show the contents of Location 1 and Location 2 as hexadecimal.
Location 1, Location 2 [2]
(b) The following machine code instruction is stored in a location of main memory:
Convert this binary pattern into hexadecimal. [4]
(c) Explain why a programmer would prefer to see the contents of the locations displayed as hexadecimal rather than binary, when debugging his program that reads the key presses. [2]
Marking Scheme:
(c) – easier to identify values
– easier to spot errors [2]
14 Some decorative lights are made up from a cluster of red, blue, green, yellow and white LEDs.
Each colour is represented by a binary code:
A 6-bit register, R1, stores the 1-values to represent a sequence of colours.
Thus, if R1 contains:
this means the blue, yellow and black colour sequence is stored and displayed in that order.
The length of time each light is on is set by a binary value in another register, R2: Thus
means each colour is on for 2 seconds.
(a) The two registers contain the following values. What is the sequence of coloured lights and the timing for each colour?
A 7-segment display is used to indicate which floor a lift is on. Each segment is numbered as shown:
A byte is used to hold the data needed to light the correct segments. Bit 0 is always zero.
For example, 3 is represented by
(a) If the lift is to stop at more than one floor, the data is held in successive bytes. For example:
Which floor numbers are stored in each byte?
First byte floor number
Second byte floor number [2]
(b) What bit pattern is used to indicate Floor 2?
(c) The lift is travelling down to stop at Floors 5, 3 and 1. When it stops at Floor 5, a passenger gets in and presses the button for Floor 2.
How does the system ensure that the lift stops at Floors 3, 2 and 1 in that order? [3]
A microprocessor controls the washing cycle of an automatic washing machine and gives output to the following devices:
• water valve • heater • wash motor • pump
Control bits are sent to turn parts of the system on or off, i.e. 1 is on and 0 is off.
(a) State what is happening when the above bit pattern is set.
.....................................................................................................................................[1]
(b) Write down the bit pattern that would be set if the water has reached the correct level, the temperature is the required temperature, the clothes have been washed and the pump is now pumping the water out of the machine.
(c) State one other process that the microprocessor could control.
.....................................................................................................................................[1]
Two 7 segment displays are used on a car dashboard to give information to the driver. Each segment is numbered as shown.
For example, the information 1P shown above is represented by:
Bit 0 is always zero
(a) What is being displayed to the driver if bytes (1) and (2) are showing?
(b) What bit patterns must be used to show the information 0L?
(c) Most of the other information on the dashboard is in analogue form.
(i) State one advantage of displaying information in analogue form.
..................................................................................................................................
...............................................................................................................................1]
(ii) State one disadvantage of displaying information in analogue form.
..................................................................................................................................
...............................................................................................................................1]
Data are the raw facts and figures that we give to a computer as input. Data lack sufficient context and processing to have meaning.
When data are processed to have context and meaning, and to search, sort and make calculations, they become known as 'information'.
Data collection and preparation
Data may need preparation after collection and before they are used as an input, to ensure that they are in the correct format.
Data are encoded to summarise them, so that they are quicker to enter, with fewer errors, occupy less memory and backing storage, and are quicker to process.
Data sometimes need to be prepared so that they have a uniform format suitable for input into a computer.
Analogue-to-digital converters and digital-to-analogue converters
An analogue input signal needs to be converted into digital data. This is done with an analogue-to-digital converter (ADC). This process is known as digitisation.
Digital output signals often need conversion to analogue signals in order to provide an output. This is done with a digital-to-analogue converter (DAC).
ADC and DAC devices can be found in a computer's sound card.
Data capture and checking
Data capture is when data actually enters the computer. This happens after data collection and data preparation. Data capture may be:
• manual
• automatic.
Inaccurate data are of little value, so their accuracy is checked by validation and verification.
Data validation
A validation check prevents the input of a data item if it is not sensible and reasonable. When this is the case, an error message is displayed. Types of validation check include:
• type
• range
• limit
• length
• character
• format or picture
• presence
• consistency
• check digit.
Data verification
Sometimes an inaccurate data item can pass validation checks due to a copying error. Verification is a way of double-checking to ensure that data remain accurate when they are copied. Common checks are:
• visual
• double entry
• parity bit.
File organisation and manipulation
• a record is a set of data usually displayed in a row of a table:
– a data field holds a specific type of data about a characteristic of the items recorded, usually displayed in a column of a table
– a record key field holds a unique identifier for each record
– a set of records are stored together as a data file
• records within files can be organised in different ways:
– a serial file
– a sequential file
– a direct access file.
File maintenance
File maintenance is the processing of a file that is not part of routine transaction processing, or updating a main file using a transaction file. Maintenance involves:
• inserting a record, e.g. a new record for a new client
• deleting a record, e.g. removing the record of a client who ends their relationship with
the organisation
• updating (amending or editing) a record, e.g. altering the record of a client who changes their address.
This usually involves rewriting the whole file for a sequential file, but not for a direct access file.
Data types
Different data types are identified so that a computer can store and process the data appropriately.
Data types include:
• string (or text)
• number (numeric):
– integer
– real (or decimal)
• currency
• date/time
• Boolean (or Yes/No).
Data structures are more complex data types, consisting of a number of data items of one or more data types. They include the record and array structures.
An array consists of a number of elements of a single data type. An array may have one or more dimensions. A program refers to an element using the array's identifier and an index number for each dimension. This approach enables efficient programs for filling an array, searching for a value in the array or generating output from its elements.
Questions:
1 A shop has four students delivering newspapers to its customers. Each student delivers three different papers (RECORDER, MAIL and ARGUS). The shop manager uses a spreadsheet to record the deliveries as shown below:
2 The terms file, record and field are used in databases. Explain the meaning of each term and explain the connections between them; you may wish to include a diagram.
3 An estate agent uses a computer system to store details about properties for sale. A section of the properties file is shown below:
a Why is coded data used for Type?
b What is the data type for Price ?
c What is meant by a key field? Which is the key field?
4 a What is meant by analogue data?
b When does analogue data need to be changed into digital data?
c What device performs the conversion?
d Give one application which would use analogue data.
5 a What is meant by digital data?
b Give one application which would use digital data.
6 Explain the following terms:
a database
b file
c direct access file
d record
e sequential file.
7 A shop sells bicycles. Information about each bicycle in stock is held in a computer file. Part of the information is shown in the table below.
a How many fields are shown?
b How many records are shown?
c Give a reason why the shop would need to delete a record from the bicycle stock file.
d Give a reason why the shop would need to add a record to the bicycle stock file.
e Explain how the shop can print a list of mountain bikes.
f There is an error in the table. Which item is wrong? How could this error have been avoided?
g Which is the key field?
8 A video club hires films to members. The club uses separate database files to store details about films, members and the films hired.
a Name four suitable items of information for the FilmsHired database file, specify the field type and give an example of the data.
b Name four suitable items of information for the Members database file, specify the field type and give an example of data.
9 a What is meant by the term 'validation'?
b What is meant by the term 'verification'?
c Describe one method of verification when changing a password.
Answers:
Below each answer there is a page reference for the coursebook. This is there to help you focus
your revision. If you find that you get an answer wrong, you can use this guide to return to the
coursebook to revise the areas that need some extra attention. Please note these are example
answers only and do not represent the only possible answers.
1 The data type in cell:
a A2 is text.
b D3 is number (or integer).
c E5 is Boolean (Yes/No).
2 A file is a collection of related data such as a set of data records. A record is a data structure
that contains items of data about a thing in the real world. Each item of data within a record is
known as a field.
3 a Coded data is used for Type because the full description would be longer. It would take up more storage space and may lead to errors in data entry.
b The data type for Price is real or decimal (numerical data type).
c A key field is an item of data that uniquely identifies a record. In this case, the key field is Property.
4 a Analogue data is data that changes continuously rather than in discrete jumps, for example, temperature or volume. It can be captured by a sensor.
b Analogue data need to be changed into digital data for it to be manipulated by a computer.
c An analogue-to-digital converter performs the conversion.
d A greenhouse control application would collect analogue temperature data and a computer would decide when to switch on and off a heater.
5 a Digital data is data that changes in discrete, or stepwise, jumps. For example, the number of bikes sold or a person's age.
b A utility billing application would use digital data from meter readings.
6 a A database is a set of tables that hold information about related things. (See glossary.)
b A file is a set of data or program items held in a named area of storage (or a physical data structure).
c A direct access file is a file stored on disk. Its records can be accessed directly by using an algorithm to generate a record's disk address from the record's key value.
d A record is a set of data items about one type of thing.
e A sequential file is a file in which records are stored in order of their record key values.
7 a There are six fields (columns) shown. (See page 9 or glossary for definition of a 'field'.)
b There are seven records (rows) shown.
c The shop would need to delete a record when a bicycle is sold.
d The shop would need to add a record when a new bicycle is delivered from the supplier.
e The shop can print a list of mountain bikes by selecting all records where the Type = 'Mountain'.
f The price of stock number 1972 is incorrect. It could have been avoided by setting a limit or range.
g The key field is StockNo.
8 A video club hires films to members.
a Four suitable items of information for the FilmsHired file are:
b Four suitable items of information for the Members file are:
9 a The term 'validation' means examining input data to ensure that it falls within pre-set criteria. For example, a date of birth must be before a certain date to be valid for a pupil to be enrolled.
b The term 'verification' means double-checking that copied data is correct.
c One method of verification when changing a password is to ask the user to type it a second time, i.e. double entry.
Summer 2010 P11;
Q15) A database has been set up to bring together information about the world's tallest buildings. A section of the database is shown below.
(a) How many records are in the section of the database shown? [1]
(b) Using Ref No. only, which records would be output if the following search condition was entered:
(Year < 1990) AND (Height (m) > 375)? [1]
(c) Write down a search condition to find out how many buildings are in China or how many buildings have more than 80 floors. [2]
(d) For each of the following fields give a different validation check.
Year
Ref No. [2]
(e) The database was sorted in descending order of Year. Using Ref No. only, write down the results of the sort. [1]
Summer 2010 P12
Q 7) A screen has been developed to allow the input of data into the following fields:
name, sex, address, date of birth and examination results.
(a) A first attempt at designing the screen is shown below:
This is not a very good input screen. Give four ways in which it could be improved.
1
2
3
4 [4]
(b) (i) What is verification?
(ii) Which fields should be verified? [3]
Q 11) A database has been set up showing information about cars:
(a) Using Car ref only, write down which cars would be output if the following search condition was used:
(No of doors = 4) AND (Fuel used (km/litre) > 15) [2]
(b) Write down a search condition to find out which cars have engines larger than 1.8 litres OR have CO2 emissions higher than 150 g/km. [2]
(c) The database is sorted in ascending order on Fuel used (km/litre). Using Car ref only, write down the results of the sort. [2]
Summer 2010 P12
Q 7 (a) Any four improvements from:
– use (text) boxes for
– names
– addresses
– sex
– date of birth
– subjects
– grades
– separate fields into separate entry items
– name into first name and last name
– address into street, city etc
– drop down list/combo box for
– date of birth
– sex
– subjects
– grades
– calendar object for
– date of birth
– radio buttons for
– sex
– hyperlinks for
– NEXT
– BACK [4]
(b) (i) any one point from:
– check on input for errors by double entry
– on screen checking
– check input is same as source
(ii) – name
– address [3]
Q 11 (a) E, H [2]
(b) (Engine (litres) > 1.8) OR (CO2 (g/km) > 150)
← (1 mark) → ← (1 mark) →
Or
(CO2 (g/km) > 150) OR (Engine (litres) > 1.8)
← (1 mark) → ← (1 mark) → [2]
(c) G, C, D, B, F, A, E, H
(1 mark for correct order (fuel used)
1 mark for ascending order) [2]