0% found this document useful (0 votes)
10 views4 pages

IOTModel QP

Internet of things

Uploaded by

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

IOTModel QP

Internet of things

Uploaded by

Sherin Joel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

RAJIV GANDHI COLLEGE OF ENGINEERING

SRIPERUMBUDUR 602 105


DEPARTMENT OF ELECTRICAL & ELECTRONCIS ENGG

ACADEMIC YEAR (2024-25)/ ODD


MODEL EXAM

CS3353-C PROGRAMMING AND DATA STRUCTURES


Dept: EEE/ECE Total Marks: 100
Year: II/Yr Duration: 3.00
Hrs
Q.NO QUESTIONS

PART A ( 10x2=20 marks)


1. Define recursion.
2. When is the ternary operator used?
3. What are preprocessor directives?
4. State the usage of union in C.
5. Specify the rules to be followed with respect to priority queue during insertion and deletion
process.
6. List few applications of doubly linked list.
7. What is an expression tree?
8. What is the preorder and postorder traversal of the below figure ?

9. What are the limitations of linear search?


10. What is the fundamental concept of merge sort?

PART B (5x13=65 marks)


11.a i)Explain how multi-way selection “Switch-case statement” implemented in C (5)
ii)Define array and Explain how it can be declared, initialized and accessed by specifying the
corresponding syntax (4)
iii)Distinguish between iterative and recursive function with suitable example (4)

OR
b. i)Why we use functions in C language. Give example. (5)
RAJIV GANDHI COLLEGE OF ENGINEERING

SRIPERUMBUDUR 602 105


DEPARTMENT OF ELECTRICAL & ELECTRONCIS ENGG

ii)Write both iterative and recursive functions in C to evaluate ab (8)

12.a i) Define macro. Write a macro to find the area of rectangle and use it in a C program.
ii)Explain the various text file opening modes and their meaning in C
iii)State and explain the pre processor directives.
OR
b. Explain the structure,nested structure and self-referential structure with example (13)
13.a i)Write and explain the algorithms of peek and display operations of stack (8)
ii)List the advantages and disadvantages of representing a group of items as an array versus a
linked list (5)
OR
b. Explain the procedure for converting an infix expression to a postfix expression using a stack.
Convert the following infix expression into a postfix expression x*(w+y/2*x^(4+x)) and
evaluate the obtained postfix expression using the values (x=1,y=2,w=3). (13)
14.a State and explain the Insertion and deletion operation in a binary search tree with example.
OR
b. i)What is a hash function? Explain the concept of hashing with an example. (8)
ii)Define Double hashing and list the advantages of the same. (5)
15.a Distinguish between min heap and Max heap. Show how heap sort processes the input 142,
543, 123, 65, 453, 879, 572, 434 , 111 ,242 , 311 and 102.
OR
i)Write and explain the algorithm of linear search. (6)
ii)Explain the basic idea behind the insertion sort and how it works. (7)
PART C (1x15=15 marks)
16.a What is open addressing? Explain the collision resolution strategies in open addressing with
examples (13)

OR
16.b Sort the sequence. 4 ,6 ,8, 2, 9 , 5, 1 , 7 and 3 using the following
i).Merge sort. (7)
ii).Quick sort ( Picking the first element as the pivot.) (8)
RAJIV GANDHI COLLEGE OF ENGINEERING

SRIPERUMBUDUR 602 105


DEPARTMENT OF ELECTRICAL & ELECTRONCIS ENGG

ACADEMIC YEAR (2024-25)/ ODD


UNIT TEST- 2

CS3353-C PROGRAMMING AND DATA STRUCTURES


Dept: EEE/ECE Total Marks: 50
Year: II/Yr Duration: 1.30
Hrs
Q.NO QUESTIONS

PART A ( 8x2=16)
1. List the advantages of linked list over arrays.
2. Write the underflow and overflow conditions in stack.
3. Outline a circular linked list with a diagram.
4. Name any four applications of queue in the field of computer applications.
5. What is a hash function?
6. When is rehashing necessary?
7. Define Separate Chaining.
8. Construct a binary tree for the expression A+(B-C) *D*(E+F).

PART B (1x8=8)
9. Write short notes on doubly linked list with few operations.

PART C (2x13=26)
10.a i) Devise an algorithm to perform push and pop operation in a stack. (8)
ii)Define ADT and list the advantages of the same. (5)

OR
10.b i) Convert the following arithmetic expression in infix form to postfix form using stack:
A+B/C+D*(E-F)^G (8)
ii)Write and explain the algorithm of enqueue operation of queue . (5)

11.a) i)What is tree traversal? Explain various methods of traversal? (7)


ii)Construct an expression tree for the expression (p+r*q) +((s*t+u) *v) (6)

OR
11.b ) .b) What is open addressing? Explain the collision resolution strategies in open addressing with
examples (13)
RAJIV GANDHI COLLEGE OF ENGINEERING

SRIPERUMBUDUR 602 105


DEPARTMENT OF ELECTRICAL & ELECTRONCIS ENGG

You might also like