CS8251 Programming in C Syllabus:
CS8251 Programming in C Syllabus – Anna University Regulation 2017
OBJECTIVES:
- To develop C Programs using basic programming constructs
- To develop C programs using arrays and strings
- To develop applications in C using functions , pointers and structures
- To do input/output and file handling in C
UNIT I BASICS OF C PROGRAMMING
Introduction to programming paradigms – Structure of C program – C programming: Data Types – Storage classes – Constants – Enumeration Constants – Keywords – Operators: Precedence and Associativity – Expressions – Input/Output statements, Assignment statements – Decision making statements – Switch statement – Looping statements – Pre-processor directives – Compilation process
UNIT II ARRAYS AND STRINGS
Introduction to Arrays: Declaration, Initialization – One dimensional array – Example Program: Computing Mean, Median and Mode – Two dimensional arrays – Example Program: Matrix Operations (Addition, Scaling, Determinant and Transpose) – String operations: length, compare, concatenate, copy – Selection sort, linear and binary search
UNIT III FUNCTIONS AND POINTERS
Introduction to functions: Function prototype, function definition, function call, Built-in functions (string functions, math functions) – Recursion – Example Program: Computation of Sine series, Scientific calculator using built-in functions, Binary Search using recursive functions – Pointers – Pointer operators – Pointer arithmetic – Arrays and pointers – Array of pointers – Example Program: Sorting of names – Parameter passing: Pass by value, Pass by reference – Example Program: Swapping of two numbers and changing the value of a variable using pass by reference
UNIT IV STRUCTURES
Structure – Nested structures – Pointer and Structures – Array of structures – Example Program using structures and pointers – Self referential structures – Dynamic memory allocation – Singly linked list – typedef
UNIT V FILE PROCESSING
Files – Types of file processing: Sequential access, Random access – Sequential access file – Example Program: Finding average of numbers stored in sequential access file – Random access file – Example Program: Transaction processing using random access files – Command line arguments
TEXT BOOKS:
1. Reema Thareja, ―Programming in C‖, Oxford University Press, Second Edition, 2016.
2. Kernighan, B.W and Ritchie,D.M, ―The C Programming language‖, Second Edition, Pearson Education, 2006
REFERENCES:
1. Paul Deitel and Harvey Deitel, ―C How to Program‖, Seventh edition, Pearson Publication
2. Juneja, B. L and Anita Seth, ―Programming in C‖, CENGAGE Learning India pvt. Ltd., 2011
3. Pradip Dey, Manas Ghosh, ―Fundamentals of Computing and Programming in C‖, First Edition, Oxford University Press, 2009.
4. Anita Goel and Ajay Mittal, ―Computer Fundamentals and Programming in C‖, Dorling Kindersley (India) Pvt. Ltd., Pearson Education in South Asia, 2011.
5. Byron S. Gottfried, “Schaum’s Outline of Theory and Problems of Programming with C”,McGraw-Hill Education, 1996.