Home /Data Structure and Algorithm

Data Structure and Algorithm B.Tech in Information Technology 3 Semester/Term 2022

Data Structure and Algorithm B.Tech in Information Technology 3 Semester/Term 2022 — page 1

Discussion

Ask a question about this paper, or help someone else with theirs. Answers are emailed to whoever asked.

Your email is only used to send you replies and occasional Ustadni updates. It is never shown publicly.

Log in to post under your name

No questions yet — be the first to ask.

Need Paper? See all →

Need a paper or stuck on a question? Ask here — students reply and you get an email.

Ask about a paper
  • Ayesha Mustafa· 2 days ago

    BS ZOOLOGY first semester Animal diversity ZOOL 101 - university of Punjab 2025

    0 replies Reply →
  • Abubakar· 2 days ago

    Literary criticism

    1 reply Reply →
  • Guest· 3 days ago

    this paper consists of 60 marks but now we have 35 marks paper.

    1 reply Reply →
  • Annie· 3 days ago

    Can you please tell me more past papers please because my exams are starting from next week

    1 reply Reply →
  • Ahmed· 7 days ago

    Did you provide the past papers of the science of society uos?

    1 reply Reply →

More Data Structure and Algorithm papers

See all

Paper text

SVKM's

D. J. Sanghvi College of Engineering

Academic Year: 2022

Program: B.Tech in Information

Technology

Date: 21.01.2023

Time: 09:00 am to 12:00 pm

Subject: Data Structures and Algorithms (Semester

III)

Duration: 3 hours

Marks: 75

Instructions: Candidates should read carefully the instructions printed on the question paper and

on the cover page of the Answer Book, which is provided for their use.

(1) This question paper contains two pages.

(2) All Questions are Compulsory.

(3) All questions carry equal marks.

(4) Answer to each new question is to be started on a fresh page.

(5) Figures in the brackets on the right indicate full marks.

(6) Assume suitable data wherever required, but justify it.

(7) Draw the neat labelled diagrams, wherever necessary.

Question

No.

Max.

Marks

QI

(a)

Write an algorithm to merge two sorted linked lists to create a new one. Take any

two sample sorted linked lists and trace your algorithm on it.

OR

Write an algorithm to insert a node into a sorted doubly linked list. Trace your

algorithm on sample sorted doubly linked list

10

QI

(b)

Write an algorithm to find the length of a circular linked list

05

Q2

(a)

Write down an algorithm, which will take a string 'S' as input. The string S is

formed using alphabets (a, b,

c) only. Find whether the input string is from the set

L = (a"b"c" | n = m + k and n. m. k 2 1). E.g., aaabbcaaaabecc € L and abbc.

aabece # L. Use appropriate data structure and justify it. Trace your algorithm on

sample input given in the example.

10

Q2

(b)

Consider the following three claims

I.

(n + k) = (n) where k and m are constants

II.

28+1=0(29)

220 = O(228)

Which of these claims are correct? Justify you answer.

OR

There are n unsorted arrays: A1. A2. ..., A. Assume that n is odd. Each of Ai. A2.

..., An contains n distinct elements. There are no common elements between any

two arrays. Find the worst-case time complexity of computing the median of the

05