Programming in ‘C’

Paper Code: 
CAI 201
Credits: 
03
Periods/week: 
03
Max. Marks: 
100.00
Objective: 

This module is designed to acquaint the students with the basics of ‘C’ programming language.

10.00
Unit I: 

Introduction to computers: Personal computing, Distributed Computing and Client/ Server Computing, Machine Languages, Assembly Languages and High level Languages, The history of C, The C standard library, Structured Programming, the basics of a typical C program Development Environment.

Introduction to ‘C’ programming: Introduction, A Simple C program, Memory Concepts, Arithmetic in C, Decision making.

Structured Program Development in C: Introduction, Algorithm, Pseudocode, Control structures, relational operator, the if selection structure, The if/else selection structure, goto statement.

8.00
Unit II: 

Operators and Expressions: Arithmetic, Logical, Assignment, Increment and Decrement, Evaluation, Precedence and Associativity of expressions.
Structured Program Development in C: The while repetition structure, Counter Controlled Repetition, Sentinel Controlled Repetition, Nested control structures.
C Program control: Introduction, Essentials of repetition, Counter controlled repetition, for repetition structure, for structure: notes and observations.

10.00
Unit III: 

C Program control: The switch multiple selection structure, the do/while repetition structure, the break and continue statements.
C Functions (Non-Recursive): Introduction, Program Modules in C, Math Library Functions, Functions, Functions Definitions, Function Prototypes, Header Files, Calling Functions: Call by Value and Call by reference, Storage Classes, Scope rules.

10.00
Unit IV: 

C Arrays: Declaring Arrays, Passing Arrays to Functions, Sorting arrays (Bubble Sort), Searching (Linear, Binary Search), Multiple-Subscripted Arrays.
Structures and Union: Definition, declaration, initialization, array of structure, arrays within structures, structures within structures.
C Pointers: Introduction, Pointer variable declaration and initialization, Pointer operators.

7.00
Unit V: 

C characters and Strings: Introduction, Fundamentals of Strings and characters, Character and String Handling Library, String conversions and comparison functions.
C Formatted Input/Output: Streams, formatting output with printf, Printing: Integers, Floating point numbers, Strings, Characters. Field Widths and Precisions, Flags in print format control string, Escape sequences, formatted input with scanf.

ESSENTIAL READINGS: 
  1. Yashwant Kanetkar, “ Working with C”,  BPB Publications.
  2. H.M. Deitel and P.J. Deitel “How to program in ‘C’”, 3rd Edition, Pearson Education.
REFERENCES: 
  1. Yashwant Kanetkar, ”Let us ‘C’”,  BPB Publication
  2. E. Balagurusami, ”Programming in ‘ANSI C’ “,  TMH Publications.
  3. Kernighan B.W, “ The C Programming Language (ANSI C) “
  4. Schaum Series, “C Programming”, TMH
  5. B.Kernighan & D.Ritchie “C Programming Language”, 2nd Edition, (Prentice-Hall, 1988). 
Academic Year: