Unit 1
Introduction and Review of C language constructs. Data types, variables, operations, statements – conditional, expressions, Functions – inter function communication, standard functions, scope. Recursion – recursive definition, recursive solution, designing recursive functions, limitations of recursion. Arrays – 1D numeric, searching and sorting, 2D numeric arrays.
Lab:
- Write a C program using conditional statements to develop a simple calculator application.
- Write a C program with functions to perform payroll computation for employees.
- Write a C program using recursion to solve the Tower of Hanoi problem.
- Write a C program to implement searching and sorting for a student marks database using 1D arrays.
- Write a C program to perform matrix addition and multiplication using 2D numeric arrays.
Unit 2
Review of programming concepts, Pointers: introduction, compatibility, arrays and pointers, Dynamic memory allocation, arrays of pointers, pointer arithmetic. Strings: fixed length and variable length strings, strings and characters, string manipulation functions, sorting of strings. Structures: structure vs array comparison, complex structures, structures and functions, Union. Files and streams, file input output, command line arguments
Lab:
- Write a C program using pointers and dynamic memory allocation to manage a student record system.
- Write a C program to implement arrays of pointers and pointer arithmetic for matrix operations.
- Write a C program to perform string manipulation for text processing applications.
- Write a C program using structures and unions to store and display employee details.
- Write a C program for file input and output to maintain a simple inventory management system
Unit 3
Data abstraction – Abstract Data Types (ADTs) and supporting language features. Lists, arrays, linked list, double and circular linked list. Stacks, queues – priority queues and applications. Hashing-hash tables, hash functions, separate chaining, open addressing, probing – linear and quadratic, rehashing and double hashing. Algorithms and comparison.
Lab:
- Write a C program to implement a singly, doubly, and circular linked list with insertion and deletion operations.
- Write a C program to implement stack and queue using arrays and linked lists.
- Write a C program to implement a priority queue with insertion and deletion operations.
- Write a C program to implement hash table with separate chaining and open addressing (linear and quadratic probing).