Effective English
Effective English
Department of Studies in
Computer Science
Reference:
1. V. Rajaraman: Fundamentals of Computers, PHI(EEE).
2. Kamthane, Programming with ANSI and Turbo C. Pearson Education, Asia.
3. Herbert Schildt: C. The complete reference, 4th edition.
4. Yeshwant Kanetkar: Let us C, BPB Publications.
5. Rajesh Hongal Computer Concepts and C Programming.
Title of Subject: PROGRAMMING IN C Lab (Major – 3)
COURSE CODE: 24MJCOMP1P CIA Marks: 10
SEMESTER: I SEE Marks: 40
Contact Hours: (L:T:P): 0-0-4 Credit: 02 Duration of Exam: 03
Part A
2. Simple C Program
o Write a C program to add two numbers and display the result. Practice
compiling and executing the program.
5. Arithmetic Operators
o Write a program to demonstrate the use of relational (==, !=, >, <, >=, <=)
and logical operators (&&, ||, !).
7. Control Structures
8. Looping Statements
o Write a program to print the first 10 natural numbers using while, do-
while, and for loops.
o Write a program to calculate the factorial of a number using a for loop.
Part B
3. String Handling
4. Pointer Basics
o Write a program to declare and initialize pointers and access the value
and address of variables using pointers.
o Write a program to demonstrate pointer arithmetic.
6. Structures
8. Unions
o Write a program to define a union for different data types (int, float,
char) and demonstrate initialization and access of union members.
o Write a program to show the difference between structures and unions
in terms of memory usage.
References Books:
1. Weiss: Data Structure and Algorithm Analysis in C, IInd Edition, Pearson Education.
2. Lipschutz: Schaum's outline series Data Structures, Tata McGraw Hill.
3. Tenenbaum: Data Structures using C, Pearson Education
Title of Subject: DATA STRUCTURES LAB (Major – 3)
COURSE CODE: 24MJCOMP2P CIA Marks: 10
SEMESTER: II SEE Marks: 40
Contact Hours: (L:T:P): 0-0-4 Credit: 02 Duration of Exam: 03
Part-A
1. Fibonacci Numbers using Recursion
o Write a program to generate Fibonacci numbers using a recursive function.
2. GCD using Recursion
o Write a program to find the greatest common divisor (GCD) of two numbers
using recursion.
3. Factorial using Recursion
o Write a program to calculate the factorial of a number using a recursive
function.
4. Comparison of Iterative and Recursive Techniques
o Write programs to compute Fibonacci numbers, GCD, and factorial using
both iterative and recursive methods. Compare their performance.
5. Array Operations
o Write a program to demonstrate basic operations on arrays (traversing,
inserting, and deleting elements).
6. Sorting Algorithms
o Implement Selection Sort, Bubble Sort, Quick Sort, and Insertion Sort on an
array and compare their performance.
7. Searching Algorithms
o Implement Sequential Search and Binary Search on an array using both
iterative and recursive approaches.
8. Multidimensional Arrays and Sparse Matrices
o Write a program to perform operations on multidimensional arrays and
demonstrate the representation of sparse matrices.
9. Stack Operations
o Implement stack operations (push, pop, display) and use the stack to convert
infix expressions to postfix.
10. Evaluation of Postfix Expressions
o Write a program to evaluate a postfix expression using a stack.
Part-B
1. Queue Operations
o Implement simple queue operations (enqueue, dequeue, display) and
demonstrate the use of circular queues.
2. Tower of Hanoi using Stack
o Write a program to solve the Tower of Hanoi problem using a stack.
3. Memory Allocation Functions
o Write a program to demonstrate the use of malloc, calloc, realloc, and free
functions for dynamic memory allocation.
4. Singly Linked List Operations
o Implement operations on a singly linked list (traversing, searching, inserting,
and deleting nodes).
5. Doubly Linked List Operations
o Implement operations on a doubly linked list (traversing, searching,
inserting, and deleting nodes).
6. Circular Linked List
o Write a program to create and perform operations on a circular linked list.
7. Binary Tree Traversals
o Write a program to create a binary tree and perform pre-order, in-order, and
post-order traversals.
8. Binary Search Tree (BST) Operations
o Implement insertion, deletion, and searching in a binary search tree.
9. Heap Tree
o Write a program to implement a heap tree and perform heap operations.
10. Reconstruction of Binary Tree
o Write a program to reconstruct a binary tree when given any two of the
traversals (pre-order, in-order, post-order).
Section – A
Note: Answer all sub questions
Each question carries TWO mark. (10 x 2 = 20)
1.
a)
b)
c)
d)
e)
f)
g)
h)
i)
j)
Section – B
Note : Answer any Four questions
Each question carries FIVE marks. (4 x 5 =20)
2.
3.
4.
5.
6.
7.
Section – C
Note : Answer any Four questions
Each question carries TEN marks. (4 x 10 =40)
8.
9.
10.
11.
12. 12.
13. 13.