Data Structure
SWE · Quiz · Fall 25
Paper 4 of 5Section A · Jobayer Ahmed Usamah - SWE (251) (2)Switch
Section A
Paper 4 of 5
Read the questions as text
Read off the PDF by AI, so it may have mistakes. The PDF is the original.
Quiz-3, SE 131 : Data Structure, Date: 09-12-2025, Section-A , Fall - 2025, Time: 20 Mins
1. A. Construct the BST, Insert the following keys in the given order to construct the BST:
[Marks 9]
50, 30, 70, 20, 40, 60, 80, 10, 25, 35, 45, 55, 65, 75, 90
B. Delete 50 from the tree and draw the tree
C. Apply BFS to find out 90 in the tree
2. Read the scenario: Riverdale City has a small but well-structured transportation network connecting several important locations. The Central Bus Terminal (CBT) acts as the main hub and has a one-way road leading to the Commercial Market (CM) with a travel time of 6 minutes. From the Commercial Market, a two-way road connects it to the City Hospital (CH), taking 4 minutes in either direction. To the north, the City Hospital (CH) has a one-way outbound road to the Fire Station (FS) requiring 5 minutes to travel. The Fire Station is linked to the Community Park (CP) through a two-way road where each side takes 7 minutes of travel. The Central Bus Terminal (CBT) also has a two-way connection to the Residential Area (RA), with a travel time of 8 minutes each way. From the Residential Area, there is a one-way shortcut to the Community Park (CP), taking 6 minutes, but the reverse direction is not allowed. Finally, the City Hospital (CH) has a two-way connection to the Residential Area (RA) with a travel time of 9 minutes in both directions, making it easier for citizens to reach medical services.
[Marks 6]
A. Draw the graph
B. Draw the Adjacency Matrix