C & Data Structure
Course Duration: 2 Months
1.1 Keywords, Constants, Variables and Data types:
Background of C – Features of C –Structure of a C Program – C Tokens - Character set – Keywords – Identifiers – Constants – Types - Variables – Declaration of a variable- Initialization of a variables – Data types – Data type modifiers -Comments – Header files.
1.2 Operators and Expressions:
Introduction – Arithmetic, Increment, Decrement, Relational, Logical, Conditional, Assignment, Short hand assignment, Bitwise , Special operators – comma and Sizeof() - Hierarchy of operations – Assignment statement - Expressions – Integer, real and mixed expressions – Type conversion – Implict and explicit conversions - printf() and scanf() functions – Escape characters - getchar() and putchar() functions – formatted and unformatted I/O functions.
1.3 Control Statements:
Simple if statement – if-else, else-if-ladder statements – switch statement - Looping Statements – while, do _ while and for loops - – go to, continue and break statements
Using Operators and Control structures
2.1 Arrays :
Definition – Array element and subscript - Declaration – Initialization of one dimension array elements - Two dimensional arrays – initialization of elements.
Introduction – Declaring ad Initializing string variables - Reading strings - Writing strings – String handling functions – strlen() , strcpy() , strcmp() , strcat() and strrev() functions programs using string functions.
Declaration and definition of function – return statement - function call – passing arguments by call by value –Types of functions – Arrays and Functions -Scope and life time of variables – auto, extern, global, register - - recursive functions Pre- defined functions : Character functions (ctype.h) – islower(), is upper(), isalpha(), to lower(), toupper() , is digit() - Math functions (math.h) – sin(), cos() , sqrt(), pow(), tan() , exp()
2.4 Programs using arrays, functions and pre-defined functions
3.1 Structures and Unions:
Structure Definition – Variable declaration – initialization – Accessing and giving values to structures - Structures within structures Arrays of structures – Arrays within structures – Functions and Structures – Unions – Declaration – initialization.
3.2 Pointers :
Introduction – Advantages of pointers – Accessing the address of a variable – Declaring and Initializing pointers – Accessing a variable through its pointer - Pointer Expressions
3.3 Relation of pointers with other elements:
Pointers and Arrays – Pointes and functions – pointers and strings - Array of pointers to strings – Limitation of array of pointers to strings – pointers and structures.
3.4 Dynamic memory allocation:
Advanatges – malloc(), calloc(), realloc(0 and free() functions
3.5 Programs using Structures, Unions and Pointers
4.1 Elementary data organization:
Data, Entity and Information - Primitive data types – Non primitive data Types – Data structure: Definition – Classification - Data structure operations.
4.2 Linked Lists:
Introduction – Singly linked list - Representation – Array implementation – pointer implementation – Traversing and searching of a linked list – Memory allocation and Garbage collection – creat() getnode() and freenode() operations - insertion at front and middle position - deletion ( front, end and if the value is given) – Two-way lists – Implementation - Operations on two-way lists – traversing and Searching – Insertion and Deletion operation ( at the front of the list only).
Definition – Representation - Operation on stacks – Algorithms -Applications of stack: Evaluation of arithmetic expression – Conversion of infix to postfix expression - Evaluation of postfix expression – Algorithms for above applications.
Definition - Representation of Queue using arrays - Circular Queue , Dequeue , Priority Queue ( Definition and Examples only).
Basic terminologies of trees – Node, Root, Parent , Child, Link, Sibling , Level, Height, Depth, Leaf , degree - Binary tree – Full binary tree and a complete binary tree - representation of binary tree – Linear representation - Advantages and disadvantages of linear representation - linked representation – traversing – Types - Traversal algorithms – Binary Search tree – inserting and searching items – Applications of Binary tree.
Types of Binary trees (Definition and examples only) : Expression tree - Heap tree – Threaded binary tree – Height balanced tree– Decision tree.
Definition - Graph terminologies – Directed and Undirected graph, Weighted graph, Adjacent Vertices, Self loop, Parallel edges, Path, Cycle, indegree, out degree, , complete graph – Connected graph - Representation of graph –- Set representation, adjacency matrix representation - Linked representation – Comparison of representations.
5.3 Searching :
Introduction - Linear searching and Binary searching – Algorithms - examples
5.4 Sorting :
Introduction – Types of sorting - Bubble sort – Selection sort – Insertion Sort – Quick Sort - Algorithms – Examples.