# A-level Computing/AQA/Paper 1/Skeleton program/2024

This is for the AQA A Level Computer Science Specification.
This is where suggestions can be made about what some of the questions might be and how we can solve them.
Please be respectful and do not vandalise the page, as this would affect students' preparation for exams!
Please do not discuss questions on this page. Instead use the discussion page.

## Section C Predictions

The 2024 paper 1 will contain 3 questions worth 11 marks in total (one 3 marker one 2 marker and one 6 marker). As long as you know the program well i.e. that understanding each line of code and and you know what each line of code does, you can also do this by using Chatgpt and Gemini and its important you use all the tools availble to you, this will be dead easy. I'm predicting this year there will be a question on Inheritance about the cell and they will ask what it means so will be worth 3 marks. Also they could be a question on overriding and they could be a question about difference from the protected, private and public methods from looking at past papers.

## Section D Predictions

Programming Questions on Skeleton Program
* The 2024 paper 1 contains 4 questions: a 5 mark, a 6 mark question and two 14 mark questions - these marks include the screen capture, so the likely marks for the coding will be 1-2 marks lower. On top of this, can someone please add some more solution in VB.net for these problems. Message for moderator - I added a question I think could come up please put a link up then delete this message - Thanks for such a brilliant resources you have provide for help for all students!
* The 2023 paper 1 contains 4 questions: a 5 mark, a 9 mark question, a 10 mark question and one 13 mark question - these marks include the screen capture(s), so the likely marks for the coding will be 1-2 marks lower.
* The 2022 paper 1 contained 4 questions: a 5 mark, a 9 mark question, a 11 mark question and one 13 mark question - these marks include the screen capture(s), so the likely marks for the coding will be 1-2 marks lower.
* The 2021 paper 1 contained 4 questions: a 6 mark, an 8 mark question, a 9 mark question and one 14 mark question - these marks include the screen capture(s), so the likely marks for the coding will be 1-2 marks lower.
* The 2020 paper 1 contained 4 questions: a 6 mark, an 8 mark question, a 11 mark question and one 12 mark question - these marks include the screen capture(s), so the likely marks for the coding will be 1-2 marks lower.
* The 2019 paper 1 contained 4 questions: a 5 mark, an 8 mark question, a 9 mark question and one 13 mark question - these marks include the screen capture(s), so the marks for the coding will be 1-2 marks lower.
* The 2018 paper 1 contained 5 questions: a 2 mark question, a 5 mark question, two 9 mark questions, and one 12 mark question - these marks include the screen capture(s).
* The 2017 paper 1 contained 5 questions: a 5 mark question, three 6 mark questions, and one 12 mark question.
Current questions are speculation by contributors to this page.

### Question 1 - Symbol Case [3 marks]

Lower case symbols are not accepted. E.g. if you enter 'q' it is not recognized as 'Q'. Fix this.
C#:
Easy solution just add .ToUpper and it will change your lowercase inputs to uppercase and allow them to work.}}
Delphi/Pascal:
Java:
Python:
VB.NET:
A simple solution, just add UCase to change all input to upper case.

### Question 2 - Game file not existing [4 marks]

If a filename is entered that does not exist, the game is unplayable (infinite loop). Amend the program so that in this case the default game is played, with a suitable message to indicate this.
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:
This helps to reset the code so that the program isn't stuck in an infinite loop trying to collect information that cannot be used. Allows the user another chance to re-enter the file name for the puzzle.
Alternative approach --> The question asks us to only accept files that exist otherwise play a default game. I have used a function instead as it is more easier to remember.
Main Sub
isValid function

### Question 3 - Blow up a block (blocked cell) [10 marks]

Have a 'bomb' that can remove or 'blow-up' a block in a 'blocked cell', but costs you some of your score (minus some points):
C#:
Delphi/Pascal:
Java:
Adding another symbol B to the list to recognise it in the process.
And add a condition to the update loop (attemptPuzzle) for the "B" symbol
Python:
This adds a new symbol "B" which can only be played on a blocked tile.
VB.NET:

### Question 4 - Add additional symbols/letters [3 marks]

Add additional letters/symbols e.g. L or O or U or V or C or H or I.
C#:
    The code here will allow you to get 10 points for creating an L shape in the grid.
Delphi/Pascal:
Java:
If you look carefully, you can spot that the pattern recognition goes in a spiral:
0_1_2
7_8_3
6_5_4
So we are going to need to map our new letter the same way:
Example of "L":
L_*_*
L_*_*
L_L_L
Next, simply follow the pattern to create a string:
Python:
The way that the pattern checking works is in clockwise. This is the order
so the pattern for Q is QQ**Q**QQ, and if you place the symbols in that order, you get the correct pattern.
VB.NET:
This allows the user to create an L pattern that results in them earning 10 points.

### Question 5 - Save current game (status) [5 marks]

Save the current status of the game (file-handling)/writing to a text file.
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:
Sub SaveGame
'cleaned version (above version has a few issues)
Cell class:
Alternative approach --> Its better to not modify the Cell class (unless its asked). I have also used string concatenation as its easier to remember during exam stress and is easier to understand/debug.
AttemptPuzzle method
SaveGame method
findSymbol method

### Question 6 - Rotated letter/symbol [9 marks]

Score a 'rotated' symbol/letter (lower score?)
C#:
Rotated letters are given 5 points rather than 10.
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 7 - Game difficulty setting [12 marks]

Offer 'game difficulty' setting to change level of game (with greater number of blocked cells)
(Important -> probably lower mark question than 11 makrs, e.g. 4 mark question)
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:
Sub Main

### Question 8 - Fix symbols placed error [9 marks]

When you try place a symbol in a invalid cell it still counts as a placed cell towards the amount of symbols placed.
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 9 - Create a new puzzle file to be imported [5 marks]

Create a new puzzle file to be imported into the code for the user to play:
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 10 - Be able to undo a move [10 marks]

Alter the attemptPuzzle subroutine such that the user is asked if they wish to undo their last move prior to the place in the loop where there is a check for symbolsLeft being equal to zero. Warn them that this will lose them 3 points.
If the player chooses to undo:
a. revert the grid back to its original state
b. ensure symbolsLeft has the correct value
c. ensure score reverts to its original value minus the 3 point undo penalty
d. ensure any changes made to a cell’s symbolsNotAllowed list are undone as required
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 11- Validation of Row and Column entries [5 marks]

Description of problem: Validate row and column number entries to only allow numbers within the grid size.
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 12 - Why is UpdateCell empty and never called?

Description of problem: Currently, the UpdateCell method contains 'pass' and is not called anywhere in the program. This will almost certainly be a question, otherwise why would they include it? This may relate to the bombing idea where a Blocked Cell is bombed, and the UpdateCell is then called to modify this Blocked Cell into a normal cell. Please suggest other ideas of what this method could be used for. Its probably used for changing a blocked cell in a pattern to a normal cell to complete a pattern.
UpdateCell could be used for unlocking a 3*3 grid if a pattern is broken allowing you to replace the symbol. This would also need to decrease the score after the pattern is broken.
C#:
There are no logical errors with GetCell as the following extract will prove
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 13 - Implement a wildcard *

Implement a special character * which is a wildcard. The wildcard can be used to represent any character so that multiple matches can be made with the same cell. Give the player 3 wildcards in random positions at the start of the game.
a) Alter the standard Puzzle constructor (not the load game one) to call ChangeSymbolInCell for 3 random cells, passing in * as the new symbol. Note that blocked cells cannot be changed to wildcard ones so you need to add code to ensure the randomly selected cell is not a blocked cell.
b) In class Cell alter the method. ChangeSymbolInCell such that wildcard cells will never have their symbol changed from * once set. In the same class, alter method CheckSymbolAllowed such that wildcard cells always return true.
c) Alter method MatchesPattern in class Pattern to allow correct operation for the new wildcard *
d) Test that a wildcard can successfully match within two different patterns
C#:
Delphi/Pascal:
Java:
Python:
Change no. 1:
while self.__wildcards_left > 0:
Change no. 2:
def MatchesPattern(self, PatternString, SymbolPlaced):
Change no. 3:
def ChangeSymbolInCell(self, NewSymbol):
def CheckSymbolAllowed(self, SymbolToCheck):
VB.NET:

### Question 14 - Program allows the user to replace already placed symbols [9 marks]

the user can replace already placed symbols, and patterns, and not lose points (can fix either by stopping them replacing, or make them lose the points from the pattern the replaced):
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 15 - Program allows the user to create their own patterns and symbols [6 marks]

Description of problem:
1) request the user to create their own symbols
2) request the pattern associated with the symbol
3) output an empty grid for the user, so the user can input any coordinates to create their own pattern
4) make sure new symbols and pattern can be verified by the program
EDIT: this would involve changing a text file or creating a new text file - AQA has never told students to do anything text file-based
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 16- Making a difficulty rating program

Description of problem:
1) this program can save each game in record including their score, number of symbols left, time to complete and the original empty grid
2) using these information to make a difficulty rating board, so the user can see their rating and select the one they want to play
C#:
Delphi/Pascal:
Java:
Python:
VB.NET:

### Question 19 - Advanced Wild Card [13 marks]

This questions refers to the class Puzzle. A new option of a wildcard is to be added to the game. When the player uses this option, they are given the opportunity to complete a pattern by overriding existing symbols to make that pattern. The wildcard can only be used once in a game.
Task 1:
Add a new option for the user that will appear before each turn. The user should be asked "Do you want to use your wildcard (Y/N)" If the user responds with "Y" then the Row, Column and Symbol will be taken as normal but then the new method ApplyWildcard should be called and the prompt for using the wildcard should no longer be shown in subsequent turns. If the user responds with "N" then the puzzle continues as normal.
Task 2:
Create a new method called ApplyWildcard that will take the Row, Column and Symbol as parameters and do the following:
1. Determine if the pattern can be completed in a 3x3 given the Row, Column and Symbol passed to it.
a) If the pattern can be made the cells in the pattern should be updated using the method UpdateCell in the Cell class and 5 points added for move.
b) If the pattern cannot be made the user should be given the message "Sorry, the wildcard does not work for this cell – you have no wildcards left"
C#:
Delphi/Pascal:
Java:
Python:

### Question 20 - Shuffle all the blocked cells [9 marks]

Implement a feature where the user can shuffle the blocked cells around.
* The new blocked cells cannot be in the same place as they were before
* They cannot overlap a matched pattern or symbol placed
Python:
Question 21 - A challenge option - where The letters the user has to place down will be randomly generated and if the user successfully does it they gain points otherwise they will lose points (10 marks)