C Programming

Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

1BCA6: C Programming

UNIT-1

Overview of C
Importance of C, Sample C programs, Basic structure of C Programs, Programming style, executing a C
Program.

Constants, Variables, and Data Types


Character set, C tokens, Keywords and identifiers, Constants, Variables, Data types, Declaration of
variables, Assigning values to variables, Defining symbolic constants
Operators and Expression
Arithmetic of Operators, Relational operators, Logical operators Assignment operators, Increment and
decrement operators, Conditional operator, Bit wise operators, Special operators, Arithmetic expressions,
Evaluation of expressions, Precedence of arithmetic operators, Type conversions in expressions, Operator
precedence and associatively, Mathematical functions.
Managing Input and Output Operations
Reading a character, writing a character, formatted input, formatted output

Unit-II

Decision Making and Branching


Decision making with IF statement, Simple IF statement, The IF ELSE statement, Nesting of IF ... ELSE
statements, The ELSE IF ladder, the switch statement, the ?: Operator, The GOTO statement.
Decision Making and Looping
The WHILE statement, The DO statement, The FOR statement, Jumps in loops
Arrays
One-dimensional arrays, Two-dimensional arrays, Initializing two-dimensional arrays.
Handling of character strings
Declaring and initializing string variables, Reading strings from terminal, Writing strings to screen,
Arithmetic operations on characters, Putting strings together Comparison of two strings, String-handling
functions, Table of strings

UNIT-III

User-Defined Functions
Need for user-defined functions, multi-function program, The form of C functions Return values and their
types, Calling a function Category of functions, Handling of non-integer functions, Nesting of functions,
Recursion, Functions with arrays, The scope and lifetime of variables in functions.
Structures and Unions
Structure definition, giving values to members, Structure initialization Comparison of structure variables,
Unions, Size of structures
Pointers and File Handling
Understanding pointers. Accessing the address of a variable, Declaring and initializing pointers, Accessing a
variable through its pointer.
File Handling– Definition and need of file. Defining, Opening, and Closing a file. Input and output
operations on files. Random access to files with example programs.

Reference Books:

1. Problem Solving with C, M.T. Somashekara, PHI Learning, New Delhi, 2009
2. Programming in ANSI C 2nd Edition by E Balaguruswamy Published by Tata McGraw Hill.

You might also like