100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.2 TrustPilot
logo-home
Exam (elaborations)

A-level COMPUTER SCIENCE Paper 1

Rating
-
Sold
-
Pages
32
Grade
A+
Uploaded on
23-03-2023
Written in
2022/2023

AQA A-level COMPUTER SCIENCE Paper 1 Time allowed: 2 hours 30 minutes Materials For this paper you must have: • a computer • a printer • appropriate software • the Electronic Answer Document • an electronic version and a hard copy of the Skeleton Program • an electronic version and a hard copy of the Preliminary Material • an electronic version of the Data Files and You must not use a calculator. Instructions • Type the information required on the front of your Electronic Answer Document. • Before the start of the examination make sure your Centre Number, Candidate Name and Candidate Number are shown clearly in the footer of every page (also at the top of the front cover) of your Electronic Answer Document. • Enter your answers into the Electronic Answer Document. • Answer all questions. • Save your work at regular intervals. Information • The marks for questions are shown in brackets. • The maximum mark for this paper is 100. • No extra time is allowed for printing and collating. • The question paper is divided into four sections. Advice You are advised to allocate time to each section as follows: Section A – 40 minutes; Section B – 20 minutes; Section C – 20 minutes; Section D – 70 minutes. At the end of the examination Tie together all your printed Electronic Answer Document pages and hand them to the Invigilator. Warning It may not be possible to issue a result for this paper if your details are not on every page of your Electronic Answer Document. Section A You are advised to spend no longer than 40 minutes on this section. Type your answers to Section A in your Electronic Answer Document. You must save this document at regular intervals. Big-O notation is used to express the time complexity of an algorithm. Table 1 contains a list of algorithms. State the Big-O time complexity of each of these algorithms. The first row has been completed for you. Table 1 Algorithm Time complexity Binary tree search O(log n) Bubble sort Linear search Merge sort Copy the contents of the unshaded cells in Table 1 into the table in your Electronic Answer Document. [3 marks] A queue data structure can be implemented as a static data structure using an array. . Describe the method that would need to be followed to attempt to remove an item from a circular queue implemented as a static data structure using an array. Your method should deal appropriately with any issues which could arise. [4 marks] . Describe three differences between dynamic and static data structures. [3 marks] Figure 1 shows data that has been stored in a stack implemented using an array S. Figure 1 [7] Top = 2 [6] [5] [4] [3] [2] Jib [1] Skye [0] Harry . What value will be returned by applying the peek operation to S? [1 mark] . What value will be returned by applying the pop operation to S? [1 mark] . Explain how a single stack can be used to reverse the order of the items in a queue. [2 marks] Turn over for the next question Turn over ► 0 3 Figure 2 shows a logic puzzle. Figure 2 . Explain why Statement 1 is not correct. [1 mark] . Which one of the six statements in Figure 2 is correct? [1 mark] . For two statements other than Statement 1 and your answer to Question 03.2, explain why those statements are not correct. [2 marks] . For each of the statements in Table 2, complete each row to indicate if the statement is true or false for Dijkstra’s algorithm. Table 2 True or False? Calculates the shortest path between a node and other nodes in a graph. Can be used to prove that the Halting Problem cannot be solved. Can be used with both directed and undirected graphs. Can be used with both weighted and unweighted graphs. Copy the contents of the unshaded cells in Table 2 into the table in your Electronic Answer Document. [2 marks] Figure 3 shows a subroutine represented using pseudo-code. The subroutine makes use of an array Visited and an array ConnectedNodes that stores a graph represented as an adjacency list. Figure 3 FUNCTION G(V, P) Visited[V]  True FOR EACH N IN ConnectedNodes[V] IF Visited[N] = False THEN IF G(N, V) = True THEN RETURN True ENDIF ELSE IF N ≠ P THEN RETURN True ENDIF ENDFOR RETURN False ENDFUNCTION . The subroutine G uses recursion. Explain what is meant by a recursive subroutine. [1 mark] Question 4 continues on the next page Turn over ► Figure 3 (repeated) FUNCTION G(V, P) Visited[V]  True FOR EACH N IN ConnectedNodes[V] IF Visited[N] = False THEN IF G(N, V) = True THEN RETURN True ENDIF ELSE IF N ≠ P THEN RETURN True ENDIF ENDFOR RETURN False ENDFUNCTION Figure 4 shows a subroutine represented using pseudo-code. The subroutine makes use of the array Visited. Figure 4 FUNCTION F() FOR Count  0 TO LENGTH(Visited) - 1 IF Visited[Count] = False THEN RETURN False ENDIF ENDFOR RETURN True ENDFUNCTION Figure 5 shows a subroutine represented using pseudo-code. The subroutine makes use of the subroutine G shown in Figure 3, the subroutine F shown in Figure 4 and the array Visited. FUNCTION E() Figure 5 Set all elements of Visited to False IF G(0, -1) = True THEN RETURN False ELSE RETURN F() ENDIF ENDFUNCTION Figure 6 shows a graph consisting of three nodes, the contents of the array ConnectedNodes when it is used to represent this graph, and the contents of the array Visited after the subroutine call G(0, -1). Figure 6 . Complete the unshaded cells in Table 3 to show the result of the subroutine call F() when it is applied using the graph shown in Figure 6. Table 3 Count Value returned Copy the contents of the unshaded cells in Table 3 into the table in your Electronic Answer Document. [2 marks] Question 4 continues on the next page Turn over ►

Show more Read less











Whoops! We can’t load your doc right now. Try again or contact support.

Document information

Uploaded on
March 23, 2023
Number of pages
32
Written in
2022/2023
Type
Exam (elaborations)
Contains
Questions & answers

Subjects

Content preview

[Type text]
COMP
AQA


A-level
COMPUTER SCIENCE
Paper 1


Time allowed: 2 hours 30
minutes
Materials
For this paper you must have:
 a computer
 a printer
 appropriate software
 the Electronic Answer Document
 an electronic version and a hard copy of the Skeleton Program
 an electronic version and a hard copy of the Preliminary Material
 an electronic version of the Data Files game1.txt and locks.txt
You must not use a calculator.

Instructions
 Type the information required on the front of your Electronic Answer Document.
 Before the start of the examination make sure your Centre Number, Candidate
Name and Candidate Number are shown clearly in the footer of every page (also at
the top of the front cover) of your Electronic Answer Document.
 Enter your answers into the Electronic Answer Document.
 Answer all questions.
 Save your work at regular intervals.

Information
 The marks for questions are shown in brackets.
 The maximum mark for this paper is 100.
 No extra time is allowed for printing and collating.
 The question paper is divided into four sections.

Advice
You are advised to allocate time to each section as follows:
Section A – 40 minutes; Section B – 20 minutes; Section C – 20 minutes; Section D – 70
minutes.

At the end of the examination
Tie together all your printed Electronic Answer Document pages and hand them to the
Invigilator.

Warning
It may not be possible to issue a result for this paper if your details are not on every
page of your Electronic Answer Document.



7517/1

,[Type text]
COMP




7517/1

, 2


Section A

You are advised to spend no longer than 40 minutes on this

section. Type your answers to Section A in your Electronic

Answer Document.

You must save this document at regular intervals.


0 notation
Big-O 1 is used to express the time complexity of an algorithm. Table 1
contains a list of algorithms.

State the Big-O time complexity of each of these algorithms. The first row has
been completed for you.

Table 1


Algorithm Time complexity

Binary tree O(log n)
search
Bubble sort

Linear search

Merge sort



Copy the contents of the unshaded cells in Table 1 into the table in your
Electronic Answer Document.
[3 marks]




2

, 3


0 2 data structure can be implemented as a static data structure using an array.
A queue

0 2 .1 Describe the method that would need to be followed to attempt to
remove an item from a circular queue implemented as a static data
structure using an array.

Your method should deal appropriately with any issues which could arise.
[4 marks]

0 2 .2 Describe three differences between dynamic and static data structures.
[3 marks]


Figure 1 shows data that has been stored in a stack implemented using an
array S.

Figure 1

[7]

[6]

[5]

[4]

[3]

[2] Jib Top = 2
[1] Skye

[0] Harry



0 2 .3 What value will be returned by applying the peek
operation to S? [1 mark]


0 2 .4 What value will be returned by applying the pop
operation to S? [1 mark]


0 2 .5 Explain how a single stack can be used to reverse the order of the items in a
queue.
[2 marks]




Turn over for the next question





3

Get to know the seller

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
Intelligentexceller17 Chamberlain College Of Nursing
View profile
Follow You need to be logged in order to follow users or courses
Sold
90
Member since
2 year
Number of followers
64
Documents
277
Last sold
1 month ago

3.8

17 reviews

5
9
4
3
3
1
2
0
1
4

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their exams and reviewed by others who've used these revision notes.

Didn't get what you expected? Choose another document

No problem! You can straightaway pick a different document that better suits what you're after.

Pay as you like, start learning straight away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and smashed it. It really can be that simple.”

Alisha Student

Frequently asked questions