AQA A Level · Computer Science 7517

Optimisation algorithms: แบบฝึกหัด

ข้อปรนัย 5 ข้อ ตรวจให้ทันทีที่ตอบ และข้อเขียน 5 ข้อ พร้อมวิธีทำละเอียด ทั้งหมดจากเรื่อง Optimisation algorithms

10 ข้อ26 คะแนนฟรี ไม่ต้องสมัคร
ข้อ 1
1 คะแนน

A programmer uses Dijkstra's shortest path algorithm to find the quickest route between two nodes in a network. Which of the following best describes how the algorithm handles a vertex once it has been 'visited'?

ข้อ 2
1 คะแนน

A specific graph-traversal algorithm is used to find the shortest path between a starting node and all other nodes in a weighted graph with non-negative edge weights. During the execution, the algorithm maintains a set of unvisited nodes and assigns each a 'tentative distance' value. Which of the following best describes the update step when the algorithm processes an unvisited neighbor \(V\) from the current node \(U\)?

ข้อ 3
1 คะแนน

An algorithm must find the shortest path between two nodes in a weighted graph with only positive edge weights. Which algorithm is most appropriate, and what is the typical graph-traversal strategy it employs?

ข้อ 4
1 คะแนน

Dijkstra's algorithm is used to find the shortest path in a graph. What is a specific requirement for the edge weights in the standard version of this algorithm?

ข้อ 5
1 คะแนน

In the context of optimisation algorithms, why might a heuristic method be used instead of an exact algorithm like Dijkstra's?

ข้อ 6
2 คะแนน

Dijkstra's algorithm is a well-known optimisation algorithm. Describe the specific condition that must be met by the edge weights in a graph for the standard version of Dijkstra's algorithm to successfully find the shortest path.

ลองเขียนคำตอบด้วยตัวเองก่อน แล้วค่อยเทียบกับวิธีทำ

ข้อ 7
3 คะแนน

Explain the significance of Dijkstra's algorithm being categorized as an optimisation algorithm and state the primary goal it achieves when applied to a weighted graph.

ลองเขียนคำตอบด้วยตัวเองก่อน แล้วค่อยเทียบกับวิธีทำ

ข้อ 8
5 คะแนน

A student is tracing Dijkstra's algorithm on a graph with nodes A, B, and C. If the current shortest distance to B is 10 and an edge (A, B) with weight 4 is processed while A has a distance of 3, describe the update step performed by the algorithm.

ลองเขียนคำตอบด้วยตัวเองก่อน แล้วค่อยเทียบกับวิธีทำ

ข้อ 9
5 คะแนน

A researcher is using Dijkstra's algorithm to find the shortest path in a weighted graph representing a local delivery network.

(a) Describe the data structures required to implement Dijkstra's algorithm efficiently.
(b) Explain why Dijkstra's algorithm may fail to find the correct shortest path if the graph contains edges with negative weights.

ลองเขียนคำตอบด้วยตัวเองก่อน แล้วค่อยเทียบกับวิธีทำ

ข้อ 10
6 คะแนน

Dijkstra's shortest path algorithm is a key optimisation algorithm for weighted graphs.

(a) Outline the general steps involved in Dijkstra's algorithm, focusing on how 'tentative distances' are updated.

(b) Explain the importance of using a priority queue (or similar data structure) to manage unvisited nodes to improve time complexity.

(c) Why does Dijkstra's algorithm require all edge weights to be non-negative? Explain what would happen if a negative edge weight were present.

ลองเขียนคำตอบด้วยตัวเองก่อน แล้วค่อยเทียบกับวิธีทำ

* เนื้อหาของ thinka สร้างโดย AI อาจไม่ถูกต้องสมบูรณ์ในทุกกรณี กรุณาใช้เป็นสื่อเสริมและตรวจสอบกับเอกสารอ้างอิงอย่างเป็นทางการ

คุณเห็นเฉลยแล้ว ทีนี้มาตรวจคำตอบของคุณบ้าง

หน้านี้บอกได้ว่าคำตอบที่ดีเป็นอย่างไร แต่บอกไม่ได้ว่าคำตอบของคุณขาดอะไร thinka ตรวจข้อเขียนของคุณตามเกณฑ์ให้คะแนนจริงในราว 15 วินาที

อยากฝึกโจทย์แบบนี้เพิ่มไหม เริ่มฝึกหัวข้อนี้ได้เลย ตรวจให้ทันทีทุกข้อ

เริ่มฝึกเลย