0% found this document useful (0 votes)
6 views3 pages

Bcse202l Fat A1 2023

The document outlines the Final Assessment Test for a Data Structures and Algorithms course, detailing various questions related to algorithm complexities, data structures, and specific programming tasks. It includes topics such as time complexity analysis, stack operations, linked list intersections, sorting algorithms, tree conversions, graph traversal, and Dijkstra’s algorithm. The test consists of ten questions, each worth 20 marks, and requires students to demonstrate their understanding through pseudocode and algorithm design.

Uploaded by

ailancer1029
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
6 views3 pages

Bcse202l Fat A1 2023

The document outlines the Final Assessment Test for a Data Structures and Algorithms course, detailing various questions related to algorithm complexities, data structures, and specific programming tasks. It includes topics such as time complexity analysis, stack operations, linked list intersections, sorting algorithms, tree conversions, graph traversal, and Dijkstra’s algorithm. The test consists of ten questions, each worth 20 marks, and requires students to demonstrate their understanding through pseudocode and algorithm design.

Uploaded by

ailancer1029
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 3
Final Assessment Test - June 2023 BCSEZ02L - Data Structures and Algorithms o Course: ts 17/S8a @ VT aii non(s):s057/sea0/seaz/se47/seao/sesi/sess/ Tenor 6304/6331 Max. Marks: Time: Three Hours |ONE/SMART WATCH, EVEN IN ‘OFF’ POSITION IS TREATED AS EXAM MALPRAC Answer ALL Questions (10 x 20 = 100 Marks) a) Find the asymptotic complexity for the function T(n) by using Recursive [5] Tree Method, where T(n) = 27(5) + vn b) Compute the time complexity of the program by showing all the steps [5] KEEPING MOBILE PH L involved. inti, j,k, a) Reversing elements of a stack using push and pop operations only. Write a [41 Pseudocode for find its time and space complexity. b) Suppose there are two singly linked lists both of which intersect at some [g) point as shown in the picture below. The head (or start) pointers of both the lists are known, but the intersecting node is not known. List1 may have n nodes before it reaches the intersection point, and List2 may have m nodes before it reaches the intersection point where m and n may be m =n, m n. Give a Procedure for finding the intersection node, Give its time and space complexity. (Note: In the below image the node is the intersection node). List 1 Lf NULL List 2 ke 1] lalgorithm for Counting Sort. Illustrate the operation of Counting sort A={4,3,1,4,2,7,9, 2, 6, 4} step by step. 2. 4 5. wa igorthm/pseudocode for printing all the elements of BST which [6] a) Devise 20 ie and K2 where K1 and K2 are integers. are between seudocode to convert a general tree into a binary tree and apply [4] v pcode to convert the following general tree into a binary tree. cy ® (QQ ~) ©®2O® ®©O®O © @® b) Waite a the pseu [5] following tasks: 15] for the given infix expression (a+ b*c)+((d*e+f) * g) Perform the a) Build an Expression tree to represent the expression. b) Convert it to prefix notation using a stack. What is the difference between the Breadth-First Search (BFS) and Depth-First Search (DFS) algorithms in graph traversal? Consider a directed graph with n nodes and m edges where each node is either black or white, how would you find the number of connected components that contain at least one black node? Which algorithm would you use and what steps would you take to solve this problem? Write the procedure for the same. Note: A connected component is a subgraph in which any two vertices are connected to each other by paths, and which is connected to no additional vertices in the subgraph. Discuss and demonstrate how Dijkstra’s algorithm can be applied to the following scenario: Imagine you are a delivery driver in a city with 9 locations. The locations are connected by roads with different travel times. You need to deliver a package from location ‘a’ to location ‘h’ as quick as possible. Estimate the total time required to deliver the package. Note; The travel time between locations are shown in the raph below: ort the keys 12, 24, 36, 49, 59, 92 g both linear using the hash function hit) =k mod 13, in table. Resolve the collls lons that occur and #4 into a has probing and double nashing Me hods. Compare the performance of the cethods while searching for 2° element in the hash table and d se wich method is more effective jetermine 4, a) Is there 2 min-heap/m2% heap with seven distinct element: i raversal of it gives ements so that th incorder traversal of it gives the elements In sorted order? Explai eal answer with justification plain your b) Write an algorithm /pseudocode for deleting an arbitrary elk E itrary elem: , heap. ent from min (sy 40. construct an AVL tree by inserting the following keys in the eye given ~ 11, 7,53, 4. Show the tree after each Insertion Then pera ote operations on the AVL tree: rm the following search for the key 11, - delete the key 17, and insert the key 8. e after each operation show the tret

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy