Computer systems
A student wrote · Data representationA student wrote: 'A logical left shift of one place always doubles the value of the binary integer.'
Why it loses marksThis is only true when no 1 is shifted off the end. The most significant bit is the one that is lost first, and when it goes the value is not doubled at all. Stating the rule without the condition is the most common loss of a mark in this topic.
The answer that scoresA logical left shift moves every bit one place to the left, shifts a 0 in at the right-hand end and loses any bit pushed off the left-hand end. If no 1 is lost the value is multiplied by 2. If a 1 is lost from the most significant bit the value is not multiplied by 2: left shifting 1100 0011 (195) by one place gives 1000 0110, which is 134, because the 1 worth 128 has been lost.
Revise this topicData representation
A student wrote · Data representationA student converted the hexadecimal number 2D to denary by writing: '2D = (2 x 10) + 13 = 33'.
Why it loses marksThe student has used denary place values on a hexadecimal number. Hexadecimal is base 16, so the place values are 16 and 1, not 10 and 1. The digit D is 13, which is correct, but it has been multiplied by the wrong place value.
The answer that scoresHexadecimal is base 16, so the place values are 16 and 1. 2D -> (2 x 16) + (13 x 1) = 32 + 13 = 45. The same answer can be checked by converting to binary first: 2D is 0010 1101, which is 32 + 8 + 4 + 1 = 45.
Revise this topicData representation
A student wrote · Data representationA student wrote: 'To write -25 in 8-bit two's complement you invert the bits of 0001 1001 to get 1110 0110.'
Why it loses marksThe student has carried out only the first of the two steps. Inverting the bits gives the one's complement, not the two's complement, and the value is out by one. Both steps are needed, and both must be shown to score.
The answer that scoresWrite +25 as 0001 1001. Invert every bit to get 1110 0110, then add 1 to get 1110 0111. So -25 is 1110 0111. You can check it: the sign bit is 1, so the value is negative, and inverting 1110 0111 gives 0001 1000, which is 24; adding 1 gives 25, so the value is -25.
Revise this topicData representation
A student wrote · Data representationA student calculated the size of an image file by dividing the number of bytes by 1000 and wrote the answer as '786 KB'.
Why it loses marksThe syllabus requires calculations to use 1024, not 1000, and the unit asked for was KiB. The method was right but the conversion factor and the unit were both wrong, so the mark was lost at the last step.
The answer that scoresFor an image of 1024 x 768 pixels with a colour depth of 8 bits: 1024 x 768 = 786 432 pixels; 786 432 x 8 = 6 291 456 bits; ÷ 8 = 786 432 bytes; ÷ 1024 = 768 KiB. Use 1024 for every step up between storage units, and give the answer in the unit the question asked for.
Revise this topicData representation
A student wrote · Data transmissionA student wrote: 'In packet switching all the packets travel along the same route to the destination, so they always arrive in the correct order.'
Why it loses marksBoth halves of this are wrong. Each packet can take a different route, and it is the router that decides the route at that moment. Because packets travel independently, they may arrive out of order and have to be reordered using the packet numbers.
The answer that scoresIn packet switching, data is broken down into packets and each packet can take a different route to the destination. A router controls the route that each packet takes, choosing the best route available at the time. The packets may therefore arrive out of order, and once the last packet has arrived the receiving device uses the packet numbers in the headers to reorder them and rebuild the data.
Revise this topicData transmission
A student wrote · Data transmissionA student wrote: 'Parallel transmission is always the better method because it sends several bits at once, so it is used for connections over long distances.'
Why it loses marksParallel transmission is faster for the same clock speed, but over distance the bits travelling down the different wires become skewed, so the receiving device reads them in the wrong order. A cable with several wires is also more affected by interference, so parallel transmission is only suitable over short distances.
The answer that scoresParallel transmission sends several bits at the same time, one down each wire, so it is faster than serial for the same clock speed, which makes it suitable for short connections. Over a long distance the bits can become skewed, so bits sent together arrive at slightly different times and the data is read incorrectly, and a multi-wire cable suffers more from interference. Serial transmission is used over long distances because there is only one stream of bits, so the data cannot become skewed and only one wire is needed.
Revise this topicData transmission
A student wrote · Data transmissionA student wrote: 'A parity check will detect any error in a transmitted byte, because the parity bit changes when the data changes.'
Why it loses marksParity can only detect an odd number of errors. If two bits in the same byte change, the number of 1s is unchanged, the parity still matches and the error goes undetected. The parity bit is also worked out by the sender from the original byte; it is not altered by the data being corrupted.
The answer that scoresA parity check adds a parity bit to each byte so that the number of 1s is always odd (odd parity) or always even (even parity). The receiver counts the 1s in each byte it receives; if the count does not match the parity being used, an error has occurred and the data is re-sent. The check only works when an odd number of bits have changed, so if two bits in the same byte are corrupted the error is not detected.
Revise this topicData transmission
A student wrote · Data transmissionA student wrote: 'Encryption stops data from being intercepted while it is being transmitted.'
Why it loses marksEncryption does not stop anyone intercepting the data; it changes the data into a form that cannot be understood without the key. The mark is for the purpose of encryption, which is to keep the data confidential even if it is intercepted.
The answer that scoresData has to pass through connections and devices that the sender does not control, so it can be intercepted. Encryption converts the data into a form that cannot be understood without the key needed to decrypt it, so even if the data is intercepted it is meaningless to anyone who does not have the key. This is why personal details, passwords and card payments are encrypted before transmission.
Revise this topicData transmission
A student wrote · HardwareA student wrote: 'The program counter holds the instruction that is currently being executed.'
Why it loses marksThe program counter holds the address of the next instruction to be fetched, not the instruction itself. The instruction that is currently being decoded and executed is held in the current instruction register. Mixing up the registers is the most common error in this section.
The answer that scoresThe program counter holds the address of the next instruction to be fetched, and it is incremented during the fetch stage so that it points to the following instruction. The instruction that has just been fetched is copied from the memory data register into the current instruction register, and the CIR is the register that holds the instruction being decoded and executed.
Revise this topicHardware
A student wrote · HardwareA student wrote: 'RAM is permanent storage that keeps the operating system safe, and ROM is temporary storage that is wiped when the computer is switched off.'
Why it loses marksThis is the wrong way round. RAM is volatile and loses its contents when the power is turned off, and ROM is non-volatile and keeps its contents. The answer also confuses primary storage with secondary storage, which is what holds files permanently.
The answer that scoresRAM is volatile primary storage: it can be read from and written to, it holds the programs and data currently in use, and its contents are lost when the power is turned off. ROM is non-volatile primary storage: it can be read but not changed, and it holds the start-up instructions the computer needs to boot. A computer needs both, because the start-up instructions must always be available and must not be lost, while the programs in use need fast, changeable storage.
Revise this topicHardware
A student wrote · HardwareA student wrote: 'Adding more cores always makes a program run faster.'
Why it loses marksMore cores only improve performance if the software has been written to split its work between them. A program that runs on a single core will not go any faster on a processor with more cores, and the clock speed and the size of the cache also affect the performance.
The answer that scoresA core is a complete processing unit, so a multi-core processor can process several instructions at the same time. More cores improve performance because more instructions are processed simultaneously, but only if the software is written to make use of more than one core. The performance of a CPU also depends on the clock speed, which is the number of cycles per second, and the size of the cache, which reduces the number of fetches from the slower RAM.
Revise this topicHardware
A student wrote · HardwareA student wrote: 'A MAC address is allocated by the router, so it changes every time the device connects to the network.'
Why it loses marksThe MAC address is given to the network interface card at the point of manufacture and it never changes. It is the IP address that is allocated by the network and that can change each time the device connects, if it is a dynamic address.
The answer that scoresA MAC address is given to the network interface card at the point of manufacture and cannot be changed. It is 48 bits long, usually written as hexadecimal in six pairs of digits, and it is created from the manufacturer code and the serial code, so it uniquely identifies the hardware. An IP address is different: it is allocated by the network, and it can be static, so it stays the same, or dynamic, so it is allocated each time the device connects.
Revise this topicHardware
A student wrote · SoftwareA student wrote: 'System software is the operating system and application software is everything else.'
Why it loses marksThis misses utility software, which is system software even though it is not the operating system. Backup programs, file compression tools, disk checkers and anti-malware are all utilities, and they provide services the computer requires rather than services the user wants.
The answer that scoresSystem software provides the services that the computer requires, and it includes both the operating system and utility software. Application software provides the services that the user requires. A backup program is system software because it maintains the computer, while the word processor that the backup is protecting is application software.
Revise this topicSoftware
A student wrote · SoftwareA student wrote: 'When an interrupt happens the program stops and has to be started again from the beginning.'
Why it loses marksThe processor does not lose the program it was running. It finishes the current instruction, saves the contents of its registers and the address of the next instruction, runs the interrupt service routine, and then restores everything it saved so the interrupted program carries on as though nothing had happened.
The answer that scoresThe processor finishes the instruction it is executing and saves the contents of its registers and the address of the next instruction. It then looks up the address of the interrupt service routine for that interrupt and jumps to it. When the ISR has finished, the saved registers and the address of the next instruction are restored, and the processor continues from exactly the point at which it was interrupted.
Revise this topicSoftware
A student wrote · SoftwareA student wrote: 'An interpreter is better than a compiler because it reports errors sooner.'
Why it loses marksThe interpreter does stop at the first error, but that is an advantage during development rather than a reason to prefer it overall. A compiled program runs faster, and the executable can be given to users who do not have the interpreter installed, which is why a compiler is used to translate the final program.
The answer that scoresAn interpreter translates and executes line by line, so it stops at the first error and reports it, which is useful while a program is being developed because the programmer gets feedback immediately. A compiler translates the whole program at once, reports all the errors it finds for the whole program, and produces an executable file that runs fast and can be used on a computer with no development software installed. An interpreter is mostly used when developing a program and a compiler is used to translate the final program.
Revise this topicSoftware
A student wrote · SoftwareA student wrote: 'Assembly language must be a high-level language because it uses words such as ADD and STO.'
Why it loses marksMnemonics are short letter codes that stand for binary opcodes, not English words. Each mnemonic corresponds to exactly one machine code instruction, so assembly language is still close to the hardware: it is a low-level language, and the programmer still has to manage registers and memory addresses.
The answer that scoresAssembly language is a low-level language that uses mnemonics in place of binary opcodes and names in place of memory addresses. Because the processor does not understand mnemonics, an assembler is needed to translate the assembly language program into machine code, replacing each mnemonic with its opcode and each named address with the actual address.
Revise this topicSoftware
A student wrote · SoftwareA student wrote: 'The compiler translates the program line by line and stops when it finds an error.'
Why it loses marksThis is the description of an interpreter. A compiler translates the whole program before any of it is executed, and it produces an error report for the whole program rather than stopping at the first problem.
The answer that scoresA compiler translates the whole program at once before executing it, and produces an executable file. If errors are detected it produces an error report for the whole code, so the programmer can fix several errors at once. An interpreter translates and executes the code line by line and stops execution when it finds an error, which is the behaviour described in the wrong answer.
Revise this topicSoftware
A student wrote · The internet and its usesA student wrote: 'The internet and the world wide web are the same thing, because you use the internet to look at websites.'
Why it loses marksUsing the internet to look at websites is exactly what makes the two easy to confuse, but they are different. The internet is the infrastructure that connects the networks; the world wide web is the collection of websites and web pages that is accessed using it, and it is only one of the services the internet carries.
The answer that scoresThe internet is the infrastructure: the global network of interconnected networks, made of cables, routers, switches and servers, over which data travels. The world wide web is the collection of websites and web pages accessed using the internet. The web therefore depends on the internet, but the internet can be used for other services such as email and video calls without any web pages being involved.
Revise this topicThe internet and its uses
A student wrote · The internet and its usesA student wrote: 'The browser asks the web server for the domain name and the web server looks up the IP address.'
Why it loses marksThe lookup is done by the DNS, not by the web server. The browser needs the IP address before it can send anything to the web server, because the web server is identified by that IP address.
The answer that scoresThe browser takes the domain name from the URL and asks the domain name server, which holds a directory matching domain names to IP addresses, and the DNS returns the IP address of the web server. The browser then sends its HTTP or HTTPS request to the web server at that IP address, and the web server returns the HTML for the page, which the browser renders and displays.
Revise this topicThe internet and its uses
A student wrote · The internet and its usesA student wrote: 'A cookie is a small program that a website installs on your computer to track you.'
Why it loses marksA cookie is a small text file holding data, not a program, so it cannot run on its own. It is also not only used for tracking: cookies save personal details, remember preferences, keep a shopping cart and store login details, which is what makes a website usable between one page and the next.
The answer that scoresA cookie is a small text file that a website stores on the user's device and that the browser sends back to that site on the next visit. Because HTTP itself keeps no memory of earlier requests, the cookie is how a site recognises a returning user. A session cookie lasts only while the browser is open and keeps one visit coherent, such as holding the contents of a shopping basket; a persistent cookie is stored on the device with an expiry date, so it can remember login details or preferences between visits.
Revise this topicThe internet and its uses
A student wrote · The internet and its usesA student wrote: 'A virus and a worm are the same thing, they both spread by email.'
Why it loses marksThe two spread in different ways, and that difference is what the question is testing. A virus needs a host file or program and spreads when the user opens or runs it, while a worm is a standalone program that copies itself across a network without any action from the user. Neither has to use email at all.
The answer that scoresA virus attaches itself to a file or a program and spreads when that file is opened or that program is run, so it needs a host and usually an action by the user. A worm is a standalone program that copies itself and spreads across a network by itself, without a host file and without the user doing anything, which is why worms can spread very quickly and use up a great deal of bandwidth.
Revise this topicThe internet and its uses
A student wrote · The internet and its usesA student wrote: 'A distributed denial of service attack is used to steal the customers' card details from a website.'
Why it loses marksThis confuses a DDoS attack with hacking or data interception. A DDoS attack is not aimed at taking data; it is aimed at making a service unavailable by flooding it with requests from a large number of compromised computers.
The answer that scoresIn a distributed denial of service attack, a large number of compromised computers are made to send requests to a server at the same time, so that the server is overwhelmed and cannot respond to genuine users. The aim is to make the service unavailable rather than to steal data. Data would be stolen by hacking or by intercepting the data while it is being transmitted.
Revise this topicThe internet and its uses
A student wrote · Automated and emerging technologiesA student wrote: 'An automated system uses a sensor to do the job and a microprocessor to store the data.'
Why it loses marksThis leaves out the actuator, which is the part that actually changes something, and it describes the microprocessor as storage rather than as the part that decides. A system with a sensor and a microprocessor but no actuator can measure and record, but it cannot act on what it finds.
The answer that scoresThe sensor measures a physical quantity and sends the reading to the microprocessor. The microprocessor compares the reading with the value stored in its program and decides what to do. If something needs to change, it signals an actuator, which carries out the physical action such as switching on a heater or opening a valve. The sensor then measures the change and the loop repeats.
Revise this topicAutomated and emerging technologies
A student wrote · Automated and emerging technologiesA student wrote: 'A robot is any machine that works automatically, such as a washing machine.'
Why it loses marksA washing machine has a motor and follows a fixed sequence, but it has no mechanical structure that carries out tasks in the world, and its sequence cannot be rewritten to give it a different job. The characteristics the syllabus asks for are a mechanical structure or framework, electrical components such as sensors, microprocessors and actuators, and being programmable.
The answer that scoresA robot has a mechanical structure or framework, so it can act physically in the world; it contains electrical components including sensors, microprocessors and actuators, which gather information, decide and move; and it is programmable, so its instructions can be written and changed. A washing machine is an automated machine, but it is not programmable in that sense and its body does not carry out varied physical tasks.
Revise this topicAutomated and emerging technologies
A student wrote · Automated and emerging technologiesA student wrote: 'AI means the computer is intelligent and can think for itself, so it knows when it is making a mistake.'
Why it loses marksThe syllabus definition is about the simulation of intelligent behaviour. The system produces behaviour that looks intelligent by processing data with rules, but it does not understand the subject or know when it is wrong unless the data and rules lead it to a different conclusion.
The answer that scoresArtificial intelligence is a branch of computer science dealing with the simulation of intelligent behaviours by computers. Its main characteristics are a collection of data and the rules for using that data, the ability to reason, and the ability to learn and adapt. The behaviour may look intelligent, but the computer is processing data according to rules rather than thinking in the way a person does.
Revise this topicAutomated and emerging technologies
A student wrote · Automated and emerging technologiesA student wrote: 'An expert system learns from experience and gets better the more it is used, just like machine learning.'
Why it loses marksThis mixes the two systems up. An expert system applies rules that a human expert has written, and those rules change only when a person changes them. It is machine learning that adapts its own processes or data as it is given more data.
The answer that scoresAn expert system reproduces the decision-making of a human expert using a knowledge base of facts, a rule base of rules written by that expert, an inference engine that applies the rules to the facts, and an interface for the user. It does not learn by itself. Machine learning is when a program has the ability to automatically adapt its own processes and/or data, finding patterns in the data it is given and improving as more data arrives.
Revise this topicAutomated and emerging technologies
A student wrote · Automated and emerging technologiesA student wrote: 'Automated systems are always better because they do not make mistakes.'
Why it loses marksAutomation has real disadvantages and this answer names none of them. A system does exactly what it was programmed to do, so an unexpected situation, a failed sensor or a programming error produces the wrong result at machine speed, and it may do so before anyone notices.
The answer that scoresAutomated systems are consistent, work continuously and can operate in conditions that would harm a person, but they are expensive to design and install, they need skilled maintenance, they can reduce the number of workers needed, and they cannot deal with anything outside their programmed rules. A failed sensor may go unnoticed, and if the system stops there may be nobody on site able to take over by hand.
Revise this topicAutomated and emerging technologies
Algorithms, programming and logic
A student wrote · Algorithm design and problem-solvingA student wrote: 'Abstraction means breaking a problem down into smaller parts.'
Why it loses marksThis describes decomposition, not abstraction. The two ideas are usually taught together, so they are easy to swap, but a question asking for one will not accept the other.
The answer that scoresDecomposition is breaking a problem down into its component parts, such as splitting an online shop into a basket, a payment system and a delivery calculator. Abstraction is removing the detail that is not needed for the problem being solved and keeping only what is, in the same way that a tube map keeps the stations and the lines but throws away the real distances.
Revise this topicAlgorithm design and problem-solving
A student wrote · Algorithm design and problem-solvingA student wrote: 'A WHILE loop repeats the statements until the condition is true, so it always runs at least once.'
Why it loses marksThe student has described a post-condition loop and given it the name of a pre-condition loop. A WHILE loop tests its condition before the statements run, so it can run zero times, and it stops when the condition becomes false, not true.
The answer that scoresA pre-condition loop (WHILE ... DO ... ENDWHILE) tests its condition before the statements are run, so the statements run only while the condition is true and may never run at all. A post-condition loop (REPEAT ... UNTIL) runs the statements first and tests the condition afterwards, so the statements always run at least once and the loop stops when the condition becomes true.
Revise this topicAlgorithm design and problem-solving
A student wrote · Algorithm design and problem-solvingA student completed a trace table by writing only the final value of the total in the last row, having worked the answer out in their head.
Why it loses marksThe marks in a trace table question are for the intermediate values of the variables after each pass through the algorithm. A single final value shows no evidence of a dry run, so only one mark at most can be earned from it.
The answer that scoresWrite one row for every pass through the loop and fill in every variable after it has changed. If four values are input, the table needs four rows, each showing the values of the total and the count at that point, followed by a final row showing what the algorithm outputs.
Revise this topicAlgorithm design and problem-solving
A student wrote · Algorithm design and problem-solvingA student wrote: 'Validation checks that the data typed into a system is correct.'
Why it loses marksValidation cannot check that data is correct, only that it is sensible and allowed. 12/04/2009 passes every validation check as a date of birth, but it would be wrong for a Year 8 pupil. Checking that the data has been entered accurately is verification, which is a different thing.
The answer that scoresValidation is an automatic check that the data is sensible and allowed, such as a range check that an exam mark lies between 0 and 100, or a presence check that a surname field is not empty. Verification is a check that the data has been entered accurately, using a visual check or a double entry check.
Revise this topicAlgorithm design and problem-solving
A student wrote · Algorithm design and problem-solvingA student wrote an algorithm to find the highest score in a list, starting with Maximum ← 0 before comparing each score with it.
Why it loses marksStarting the maximum at 0 only works if every score in the list is positive. If the list contains negative numbers, or if the first value is the largest, the algorithm can output a value that was never in the list at all.
The answer that scoresSet the maximum to the first value in the list, Maximum ← Score[1], and then compare the remaining values with it from the second element onwards. That way the maximum always starts as a value that really is in the list, and the algorithm works whatever the numbers are.
Revise this topicAlgorithm design and problem-solving
A student wrote · ProgrammingA student wrote the assignment the wrong way round: 10 ← Score.
Why it loses marksThe arrow always points from the value to the variable, because the value on the right is stored in the identifier on the left. Written this way round the statement tries to change the number 10, which is impossible, and the mark is lost.
The answer that scoresThe correct statement is Score ← 10, which stores the value 10 in the variable Score. The assignment operator ← replaces whatever was in the variable, so Score ← Score + 1 increases Score by one by working out the right-hand side first and then storing the result.
Revise this topicProgramming
A student wrote · ProgrammingA student declared DECLARE AverageMark : INTEGER and then used it to store the average mark of a class, which came out as 67.5.
Why it loses marksA value with a fractional part cannot be stored in an INTEGER variable, which holds whole numbers only. Either the program reports an error or the 0.5 is lost, and either way the answer is wrong.
The answer that scoresDeclare the variable as REAL, because an average can contain a fractional part: DECLARE AverageMark : REAL. Use INTEGER only for values that are whole numbers by their nature, such as the number of pupils in a class or a count of correct answers.
Revise this topicProgramming
A student wrote · ProgrammingA student put Total ← 0 inside a FOR loop that was meant to add up ten numbers, so the total only ever held the last number entered.
Why it loses marksSetting the total to 0 inside the loop wipes out everything added so far on every pass. The loop then runs ten times but only the final value survives, so the total is wrong and the average worked out from it is wrong too.
The answer that scoresInitialise before the loop and update inside it: Total ← 0 comes before the FOR statement, and Total ← Total + Number sits inside the loop. The same rule applies to a counting variable, which must be set to 0 before the loop and increased by 1 inside it.
Revise this topicProgramming
A student wrote · ProgrammingA student called a function using CALL, writing CALL Average(Total, Count).
Why it loses marksA function returns a value, so it is called as part of an expression rather than as a statement. CALL is used only with procedures, and putting it in front of a function loses the mark for the call.
The answer that scoresUse the function inside an expression, for example OUTPUT Average(Total, Count) or AverageScore ← Average(Total, Count). Use CALL only for a procedure, such as CALL DisplayHeading, which returns no value.
Revise this topicProgramming
A student wrote · ProgrammingA student wrote a loop as WHILE Count < 10 DO ... UNTIL Count = 10.
Why it loses marksThe two kinds of loop have been mixed together. A WHILE loop is a pre-condition loop and is closed with ENDWHILE, while REPEAT UNTIL is a post-condition loop that tests its condition at the end. The mixture cannot be executed and shows the examiner that the difference between the two loops is not understood.
The answer that scoresChoose one form and complete it. A pre-condition loop is WHILE Count < 10 DO ... ENDWHILE, which may run zero times. A post-condition loop is REPEAT ... UNTIL Count = 10, which always runs at least once and stops when the condition becomes true.
Revise this topicProgramming
A student wrote · DatabasesA student wrote: 'ProductName should be the primary key, because every product has a name.'
Why it loses marksA primary key must be unique to each record, and a name does not guarantee that. Two different products can both be called Kettle, and then two records would hold the same key value, which is exactly what a primary key must prevent.
The answer that scoresProductCode is the primary key, because every product has its own code and no two records share one. ProductName cannot be the key: a shop may sell two different products that share a name, so the field would not identify one record uniquely. A primary key must also have a value in every record and must never change, which a product code satisfies.
Revise this topicDatabases
A student wrote · DatabasesA student wrote: 'Price should be stored as an integer, because a price is a number.'
Why it loses marksAn integer field holds whole numbers only. A price such as 24.50 has a fractional part, so an integer field would lose the 50p and the shop could not add up its takings correctly.
The answer that scoresPrice must be a real, because it has a fractional part: 24.50, 18.00 and 39.99 are all prices. Integer is right for a whole-number field such as QuantityInStock. The same test explains why a telephone number is text/alphanumeric rather than integer - it is never added up, and an integer would drop a leading zero.
Revise this topicDatabases
A student wrote · DatabasesA student wrote: 'Validation makes sure the data stored in the database is correct.'
Why it loses marksValidation only checks the data against a rule, so it rejects impossible values. It cannot tell whether a sensible value is the right one, which is why it is often said that validation checks the data but does not verify it.
The answer that scoresValidation checks that data is sensible before it is stored: a range check rejects a quantity of 700, a length check rejects a product code of three characters and a presence check rejects an empty name field. It cannot make the data correct, because a price of 24.50 typed as 24.05 passes every check and is still the wrong price.
Revise this topicDatabases
A student wrote · DatabasesA student wrote: 'SELECT ProductName FROM Stock ORDER BY Price DESCENDING gives the products from cheapest to most expensive.'
Why it loses marksDESCENDING means largest first, so the most expensive product comes at the top of the output. The student has read DESCENDING as 'in order' rather than as 'in descending order'.
The answer that scoresORDER BY Price DESCENDING puts the records in order of price with the largest price first, so the most expensive product is at the top of the output. ORDER BY Price ASCENDING would give the cheapest first. The WHERE clause, not the ORDER BY, is what decides which records appear at all.
Revise this topicDatabases
A student wrote · DatabasesA student wrote: 'SELECT COUNT(Price) FROM Stock gives the total of all the prices in the table.'
Why it loses marksCOUNT counts records; SUM adds values. The student has used COUNT where the question needed a total, so the answer would be the number of records rather than the sum of the prices.
The answer that scoresSELECT SUM(Price) FROM Stock adds up the price field and gives the total. SELECT COUNT(Price) FROM Stock counts how many records were selected and gives a number of records. Both return a single number rather than a list, which is why they are easy to confuse.
Revise this topicDatabases
A student wrote · Boolean logicA student wrote: 'A NAND gate gives an output of 1 when both of its inputs are 1.'
Why it loses marksThis is the AND gate's function, not NAND's. The student has ignored the circle on the output of the NAND symbol, and that circle is a NOT, which reverses the output of the gate.
The answer that scoresA NAND gate outputs 0 only when both inputs are 1, and 1 in the other three rows of its truth table, which makes it the exact opposite of AND. The circle on the output of the symbol is the NOT that reverses AND's output. For inputs 0 and 1, an AND gate gives 0 and a NAND gate gives 1.
Revise this topicBoolean logic
A student wrote · Boolean logicA student wrote: 'An XOR gate gives an output of 1 when both of its inputs are 1, because it works like OR.'
Why it loses marksThe student has read XOR as if it were OR. XOR is the exclusive OR, and the word exclusive is the whole point: it excludes the case where both inputs are 1.
The answer that scoresAn XOR gate outputs 1 when the two inputs are different, so it gives 1 for inputs 0 and 1 and for inputs 1 and 0, and 0 when both inputs are 1 or both are 0. An OR gate, by contrast, outputs 1 when both inputs are 1. The extra curved line across the inputs of the XOR symbol is what marks this difference.
Revise this topicBoolean logic
A student wrote · Boolean logicA student wrote: 'A circuit with three inputs needs six rows in its truth table, one for each input plus one for each combination.'
Why it loses marksThe number of rows is not related to the number of inputs in that way. Every combination of three binary inputs must appear, and there are 2 to the power 3 = 8 of them.
The answer that scoresA truth table needs one row for every possible combination of the inputs: 2 to the power 3 = 8 rows for three inputs, and 2 to the power 2 = 4 rows for two inputs. Write them in binary counting order, 000, 001, 010, 011, 100, 101, 110, 111, so that every combination appears exactly once.
Revise this topicBoolean logic
A student wrote · Boolean logicA student wrote: 'I used one AND gate instead of two, because the two circuits do the same thing.'
Why it loses marksThe syllabus requires the circuit to be drawn for the statement given, without simplification. A neat circuit that behaves in the same way is still not the circuit the question asked for, and the marks are for the gates the statement implies.
The answer that scoresCircuits must be drawn for the statement given, without simplification. If the statement says the output is 1 when A and B are both on, or when A and C are both on, the circuit is two AND gates feeding an OR gate. Simplifying that to A AND (B OR C) would give the same output but is not the circuit the statement describes.
Revise this topicBoolean logic
A student wrote · Boolean logicA student wrote the expression for a circuit as: Q = A AND B OR C
Why it loses marksWithout brackets the expression can be read in two ways, and the two readings are different circuits: (A AND B) OR C gives 1 when A is 0, B is 0 and C is 1, while A AND (B OR C) gives 0 for the same inputs.
The answer that scoresBracket the output of every gate so the order is unambiguous. If the circuit has A and B into an AND gate and the output of that gate into an OR gate with C, the expression is Q = (A AND B) OR C. If the circuit has B and C into an OR gate and the output of that gate into an AND gate with A, it is Q = A AND (B OR C).
Revise this topicBoolean logic