AQA GCSE Computer Science Past Papers | Mark Schemes
Match AQA paper and programming-language variants before practising Boolean logic and tracing algorithms.
Quick Answer
The AQA GCSE Computer Science archive includes question papers and mark schemes, including GCSE Computer Science Paper 1A – Computational Thinking and Programming Skills (C#). Match the assessment code and series before using the scheme to check your working.

Trace a loop with a boundary case
A program starts a total at zero and adds every value that is at least five from the list four, five, eight. After four, the total stays zero. Five qualifies because the comparison includes equality, so the total becomes five. Eight takes it to thirteen. Draw a trace table with a row for each input and a separate column for the condition. A final output of eight suggests the program tested strictly greater than five.
Use and Apply the Conditional to Construct a Truth Table
| T | T | T |
| T | F | F |
| F | T | T |
| F | F | T |
Constructing Truth Tables for Conditional Statements
- Because is true and is true, the statement is, “If my sibling washed the dishes, then my parents paid them $5.00.” My sibling did wash the dishes, since is true, and the parents did pay the sibling $5.00, so the contract was entered and completed. The conditional statement is true, as indicated by the truth table representing this case: T → T = T.
T T T - translates to the statement, “If my sibling washed the dishes, then my parents did not pay them $5.00.” is true, but is false. The sibling completed their end of the contract, but they did not get paid. The contract was broken by the parents. The conditional statement is false, as indicated by the truth table representing this case: T → F = F.
T T F F - translates to the statement, “If my sibling did not wash the dishes, then my parents paid them $5.00.” is false, but is true. The sibling did not do the dishes. No contract was entered, so it could not be broken. The parents decided to pay them $5.00 anyway. The conditional statement is true, as indicated by the truth table representing this case: F → T = T.
T T F T
Determining Validity of Conditional Statements
- Applying the dominance of connectives, the statement is equivalent to So, the columns of the truth table will include , , , and Because there are only two basic propositions, and , the table will have rows of truth values to account for all the possible outcomes. The statement is not valid because the last column is not all true.
T T T F F T F F T T F T F F T F F F T T - Applying the dominance of connectives, the statement is equivalent to So, the columns of the truth table will include , , , and Because there are only two basic propositions, and , the table will have rows of truth values to account for all the possible outcomes. The statement is not valid because the last column is not all true.
T T F T T T F F F F F T T T T F F T T T
Use and Apply the Biconditional to Construct a Truth Table
| T | T | T |
| T | F | F |
| F | T | F |
| F | F | T |
Constructing Truth Tables for Biconditional Statements
- Because is true and is true, the statement is “The plumber fixed the leak if and only if the homeowner paid them $150.00.” Because both and are true, the leak was fixed and the plumber was paid, meaning both parties satisfied their end of the bargain. The biconditional statement is true, as indicated by the truth table representing this case: T ↔ T = T.
T T T - translates to the statement, “The plumber fixed the leak if and only if the homeowner did not pay them $150.” If the plumber fixed the leak and the homeowner did not pay them, the homeowner will have broken their end of the contract. The biconditional statement is false, as indicated by the truth table representing this case: T ↔ F = F.
T T F F - translates to the statement, “The plumber did not fix the leak if and only if the homeowner did not pay them $150.” In this case, neither party—the plumber nor the homeowner—entered into the contract. The leak was not repaired, and the plumber was not paid. No agreement was broken. The biconditional statement is true, as indicated by the truth table representing this case: F ↔ F = T.
T T F F T
Determining Validity of Biconditional Statements
- Applying the dominance of connectives, the statement is equivalent to So, the columns of the truth table will include , , , and Because there are only two basic propositions, and , the table will have rows of truth values to account for all the possible outcomes. The statement is not valid because the last column is not all true.
T T T F F F T F F T T F F T F F F T F F F T F T - Applying the dominance of connectives, the statement is equivalent to So, the columns of the truth table will include , , , and Because there are only two basic propositions, and , the table will have rows of truth values to account for all the possible outcomes. The statement is not valid because the last column is not all true.
T T T F T T T F T F F F F T T T T T F F F T T F - Applying the dominance of connectives, the statement is equivalent to So, the columns of the truth table will include , , , , and Because there are only two basic propositions, and the table will have rows of truth values to account for all the possible outcomes. The statement is valid because the last column is all true.
T T T F F T T T F F T F F T F T T F T T T F F T T T T T - Applying the dominance of connectives, the statement is equivalent to So, the columns of the truth table will include , , , , and Because there are three basic propositions, , , and , the table will have rows of truth values to account for all the possible outcomes. The statement is not valid because the last column is not all true.
T T T F T F T T T T F T T T F T T F T F F T F F T F F T F T F F F T T F F T F F F T F T F T F F F F T F F T F F F F F T F T F F
Check Your Understanding
Video
- Logic Part 8: The Conditional and Tautologies
- Logic Part 11B Biconditional and Summary of Truth Value Rules in Logic
- Logic Part 13: Truth Tables to Determine if Argument is Valid or Invalid
Interpret and Apply Negations, Conjunctions, and Disjunctions
Finding the Truth Value of a Negation
- :
- : All horses are mustangs.
- : New Delhi is not the capital of India.
- is true because 3 + 5 does equal 8; therefore, the negation of , , is false.
- is false because there are other types of horses besides mustangs, such as Clydesdales or Arabians; therefore, the negation of , , is true.
- is false because New Delhi is the capital of India; therefore, the negation of , , is true.
Finding the Truth Value of a Conjunction
- is true, and is false. Because one statement is true, and the other statement is false, this makes the complete conjunction false.
- is false, so is true, and is true. Therefore, both statements are true, making the complete conjunction true.
- is false, and is false. Because both statements are false, the complete conjunction is false.
Finding the Truth Value of a Disjunction
- is true, and is false. One statement is true, and one statement is false, which makes the complete disjunction true.
- is false, so is true, and is true. Therefore, one statement is true, and the other statement is true, which makes the complete disjunction true.
- is false, and is false. When all of the component statements are false, the disjunction is false.
Finding the Truth Value of Compound Statements
- Step 1: The statement “” contains three basic logical statements, , , and , and three connectives, When we place parentheses in the statement to indicate the dominance of connectives, the statement becomes Step 2: After we have applied the dominance of connectives, we create a two row table that includes a column for each basic statement that makes up the compound statement, and an additional column for the contents of each parentheses. Because we have three sets of parentheses, we include a column for the innermost parentheses, a column for the next set of parentheses, and in the last column for the third parentheses. Step 3: Once the table is created, we determine the truth value of each statement starting from left to right. The truth values of , , and are true, false, and true, respectively, so we place T, F, and T in the second row of the table. Because is true, is false. Step 4: Next, evaluate from the table: is false, and is also false, so is false, because a conjunction is only true if both of the statements that make it are true. Place an F in the table below its heading. Step 5: Finally, using the table, we understand that is false and is true, so the complete statement is false or true, which is true (because a disjunction is true whenever at least one of the statements that make it is true). Place a T in the last column of the table. The complete statement is true.
T F T F F T - Step 1: Applying the dominance of connectives to the original compound statement , we get
Step 2: The table needs columns for and
Step 3:The truth values of , , , and are the same as in Question 1.
Step 4: Next, is false or false, which is false, so we place an F below this statement in the table. This is the only time that a disjunction is false.
Step 5: Finally, and are the conjunction of the statements, and , and so the expressions evaluate to false and true, which is false. Recall that the only time an "and" statement is true is when both statements that form it are also true. The complete statement is false.
T F T F F F - Step 1: Applying the dominance of connectives to the original statement, we have: .
Step 2: So, the table needs the following columns: and
Step 3: The truth values of , , and are the same as in Questions 1 and 2.
Step 4: From the table it can be seen that is true and true, which is true. So the negation of and is false, because the negation of a statement always has the opposite truth value of the original statement.
Step 5: Finally, is the disjunction of with , and so we have false or false, which makes the complete statement false.
T F T T F F
Construct Truth Tables to Analyze All Possible Outcomes
| Negation | |
| T | F |
| F | T |
| Conjunction (AND) | Disjunction (OR) | |||||
| T | T | T | T | T | T | |
| T | F | F | T | F | T | |
| F | T | F | F | T | T | |
| F | F | F | F | F | F |
Constructing Truth Tables to Analyze Compound Statements
- Step 1: Because there are two basic statements, and , and each of these has two possible outcomes, we will have rows in our table to represent all possible outcomes: TT, TF, FT, and FF. The columns will include , , , and
Step 2: Every value in column will have the opposite truth value of the corresponding value in column : F, T, F, and T.
Step 3: To complete the last column, evaluate each element in column with the corresponding element in column using the connective or.
T T F T T F T T F T F F F F T T - Step 1: The columns will include , , and . Because there are two basic statements, and , the table will have four rows to account for all possible outcomes.
Step 2: The column will be completed by evaluating the corresponding elements in columns and respectively with the and connective.
Step 3: The final column, , will be the negation of the column.
T T T F T F F T F T F T F F F T - Step 1: This statement has three basic statements, , , and . Because each basic statement has two possible truth values, true or false, the multiplication principal indicates there are possible outcomes. So eight rows of outcomes are needed in the truth table to account for each possibility. Half of the eight possibilities must be true for the first statement, and half must be false.
Step 2: So, the first column for statement , will have four T’s followed by four F’s. In the second column for statement , when is true, half the outcomes for must be true and the other half must be false, and the same pattern will repeat for when is false. So, column will have TT, FF, FF, FF.
Step 3: The column for the third statement, , must alternate between T and F. Once, the three basic propositions are listed, you will need a column for, , and .
Step 4: The column for the negation of , , will have the opposite truth value of each value in column .
Step 5: Next, fill in the truth values for the column containing the statement The or statement is true if at least one of or is true, otherwise it is false.
Step 6: Finally, fill in the column containing the conjunction . To evaluate this statement, combine column and column with the and connective. Recall, that only time "and" is true is when both values are true, otherwise the statement is false. The complete truth table is:
T T T F T T T T F F T F T F T T T T T F F T T F F T T F F F F T F F F F F F T T T T F F F T T F
Determine the Validity of a Truth Table for a Compound Statement
Determining the Validity of Compound Statements
- Step 1: Because there are two statements, and , and each of these has two possible outcomes, there will be rows in our table to represent all possible outcomes: TT, TF, FT, and FF.
Step 2: The columns, will include , , and Every value in column will have the opposite truth value of the corresponding value in column .
Step 3: To complete the last column, evaluate each element in column with the corresponding element in column using the connective and . The last column contains at least one false, therefore the statement is not valid.
T T F F T F F F F T T T F F T F - Step 1: Because the statement only contains one basic proposition, the truth table will only contain two rows. Statement may be either true or false.
Step 2: The columns will include , , and Evaluate column with the and connective, because the symbol represents a conjunction or logical and statement. True and false is false, and false and true is also false.
Step 3: The final column is the negation of each entry in the third column, both of which are false, so the negation of false is true. Because all the truth values in the final column are true, the statement is valid.
T F F T F T F T
Check Your Understanding
Video
- Logic Part 2: Truth Values of Conjunctions: Is an "AND" statement true or false?
- Logic Part 3: Truth Values of Disjunctions: Is an "OR" statement true or false?
- Logic Part 4: Truth Values of Compound Statements with "and", "or", and "not"
- Logic Part 5: What are truth tables? How do you set them up?
- Logic Part 6: More on Truth Tables and Setting Up Rows and Column Headings
Law of Detachment
| Law of Detachment | |
| Premise: | |
| Premise: | |
| Conclusion: |
| T | T | T |
| T | F | F |
| F | T | T |
| F | F | T |
| T | T | T | T | T |
| T | F | F | F | T |
| F | T | T | F | T |
| F | F | T | F | T |
Applying the Law of Detachment to Determine a Valid Conclusion
- If Leonardo da Vinci was an artist, then he painted the Mona Lisa. Leonardo da Vinci was an artist.
- If Michael Jordan played for the Chicago Bulls, then Michael Jordan was not a soccer player. Michael Jordan played for the Chicago Bulls.
- If all fish have gills, then clown fish have gills. All fish have gills.
- The premises are If Leonardo da Vinci was an artist, then he painted the Mona Lisa, and Leonardo da Vinci was an artist. This argument has the form of the law of detachment, so, the conclusion is Leonardo da Vinci painted the Mona Lisa.
- The premises follow the form of the law of detachment, so a valid conclusion would be . The premises are If Michael Jordan played for the Chicago Bulls, then Michael Jordan was not a soccer player, and Michael Jordan played for the Chicago Bulls. The conclusion that follows from the premises is Michael Jordan was not a soccer player.
- The premises are If all fish have gills, then clown fish have gills, and All fish have gills. This argument has the form of the law of detachment, so the conclusion is clown fish have gills.
