Roll No.
___________________
KIET Group of Institutions
CT Examination (2023-2024) ODDSemester
Department: CSE/IT/CS/CSIT/CSE(AI)/CSE(AI&ML) Course: B.Tech.
Year: II Semester: III
Subject Name: Data Structure Subject Code: BCS 301
Duration: 2 Hrs. Max. Marks: 60
Note: Attempt all the questions of each section
Section-A (2X10=20)
Q. 1 Competitive
Exam# CO BL/ KC*
a Define data types. What are built in data types in C ? Explain 1 1/C
b Explain the criteria of an algorithm. 1 2/C
c What do you understand by complexity of an algorithm? Compute the AKTU 4 2/C
worst case complexity for the following C code : 2014-15
main()
{
int s = 0, i, j, n;
for (j = 0; j < (3 * n); j++)
{
for (i = 0; i < n; i++)
{ s = s + i;
}
printf(“%d”, i);
}}
d Explain advantage of Array over Linked List. AKTU 1 2/C
2014-15
e Explain time complexity and space complexity of an algorithm with AKTU 4 2/C
example. 2015-16
f Derive the O-notation for linear search. 4 2/C
g Describe Stack. 2 2/C
h Describe Time Space Tradeoff. AKTU 4 1/F
2017-18
i Derive a C function to find size of a singly linked list. 1 3/C
j Explain Array storage of Sparse Matrix. 1 2/C
Section-B (5X4=20)
Derive a C function for Linked list implementation of stack. Write all
the primitive operations.
Q. 2 OR 2 3/C
Derive the Push and Pop functions in C simulating Push and Pop
operations of stack implemented using an array of integers.
Q. 3 Suppose multidimensional arrays PPP and QQQ are declared as PPP (- 1 3/F
2:9, 2:21) andQQQ (-1:8, 1:6, 0:9) stored in row- major order
(i) Examine the length of each dimension of PPP and QQQ AKTU
(ii) Examine the number of elements in PPP and QQQ 2018-19
Assuming Base address (QQQ) = 1020, w = 4, Find the effective indices
E1, E2, E3 and address of the element QQQ [5, 5, 5].
OR
● CO -Course Outcome generally refer to traits, knowledge, skill set that a student attains after completing the course successfully.
● Bloom’s Level (BL) - Bloom’s taxonomy framework is planning and designing of assessment of student’s learning.
● *Knowledge Categories (KCs): F-Factual, C-Conceptual, P-Procedural, M-Metacognitive
● #Reference to Competitive Exams (GATE, GPAT, CAT, GRE, TOFEL, NET, etc. )
Roll No. ___________________
Derive the row major order concept? Illustrate with an example.
Determine addressing formula to find the location of (i, j) th element of
Q. 4
a m × n matrix stored in column major order. 1 3/C
OR
Derivea C function to add two polynomials represented by linked list.
Express a C function to display alternate node of a singly linked list.
OR
Q. 5 1 3/C
Derive a C function to find all even values from singly linked list of
integers.
Section-C (10X2=20)
Derive C functions to insert a node at the beginning, and delete the last
AKTU
node from a Doubly Linked list. Also state the advantages and
2015-16
Q. 6 disadvantages of Doubly Linked list. 1 3/C
OR
Express C functions to check given linked list is Palindrome or not.
Express the C functions to insert a node at the end, and delete the first
node from Circular Linked list. Also state the advantages and
disadvantages of Circular Linked list.
OR
Consider an empty stack of integers. Let the numbers 1, 2, 3, 4, 5, 6 be
Q. 7 pushed on to this stack in the order they appear from left to right. Let S 2 3/C
indicates a push and X indicates a pop operation. Can they be permuted
in to the order:
i. 325641 (output) and
ii. 154623(output)
Simulate the steps in order to get above orders.
● CO -Course Outcome generally refer to traits, knowledge, skill set that a student attains after completing the course successfully.
● Bloom’s Level (BL) - Bloom’s taxonomy framework is planning and designing of assessment of student’s learning.
● *Knowledge Categories (KCs): F-Factual, C-Conceptual, P-Procedural, M-Metacognitive
● #Reference to Competitive Exams (GATE, GPAT, CAT, GRE, TOFEL, NET, etc. )