Syllabus - CS1 : Programming in C

CS1 : Programming in C
(6 Hours – 4 Credits)
UNIT I

Overview of C: History of C – Importance of C – Basic structure of C – Programming style – Constants,  variables and Data types – declaration of variables,  storage class – defining symbolic constants – declaring a variable as constant,  volatile – overflow and underflow of data.   Operators and expressions: arithmetic,  relational,  logical,  assignment operators – increment and decrement operators,  conditional operators,  bitwise operators,  special operators – arithmetic expression – evaluation of expressions – precedence of arithmetic operators – type conversions in expression – operator precedence and associativity – mathematical functions – managing I/O operations: reading and writing a character – formatted input,  output.   


UNIT II

Decision making and branching: if statement,  if….  else statement – nesting of if ….  else statement – Else if Ladder – Switch statement – the ?: operator – goto statement. 
The While statement – do statement – The for statement – jumps in loops

UNIT III

Arrays: one dimensional array – declaration,  initialisation – two dimensional array – multi dimensional array – dynamic arrays – initialisation.   Strings: declaration,  initialisation of string variables – reading and writing string – arithmetic operations on strings – putting strings together – comparison – string handling function – table of strings – features of string. 

UNIT IV

User defined functions: need – multi function program – elements of user defined function – definition – return values and their types – function calls,  declaration,  category – all types of arguments and return values – nesting of functions – recursion – passing arrays,  strings to functions – scope visibility and life time of variables – multi file programs.   Structures and unions: defining a structure – declaring structure variables – accessing structure members – initialisation – copying and comparing – operations on individual members – arrays of structures – arrays within structures – structures within structures – structures and functions – Unions – size of structures – bit fields. 

UNIT V

Pointers:  accessing the address of a variable – declaring,  initialisation of pointer variables – accessing a variable through its pointer – chain of pointers – pointer expressions – pointer increment and scale factors – pointers and arrays – pointers and character strings – array of pointers – pointers as function arguments – function returning pointers – pointers to functions – pointers and structures.   Files: defining,  opening,  closing a file.   I/O operations on files – error handling during I/O operations – random access to file – command line arguments. 


Text Book:
1.      E.   Balagurusamy,  “Programming in ANSI C”,  Edition3,  Tata McGraw Hill Publishing Company,  2005. 

UNIT I :  Chapters: 1 – 4    UNIT II : Chapter 5, 6    UNIT III : Chapters 7,  8
UNIT IV : Chapters 9,  10    UNIT V : Chapter 11,  12


Reference Book:
     Programming with C  (Schaum’s Outline Series),  Gottfried,  Tata McGraw Hill,  2006. 


No comments

Powered by Blogger.