L 3 C 3
Teachers Continuous Evaluation: as per university examination norms. End Term Theory Examination: as per university examination norms.
Course outcomes
- Understand the basic structure of C programming, number systems, and the compilation process of a C program. [K1]
- Apply programming constructs like operators, loops, conditionals, and arrays in C to solve problems. [K2]
- Analyze and implement advanced programming constructs such as functions, recursion, strings, and pointers. [K1,K2]
- Develop and implement programs involving structures, unions, and file handling. [K2]
Unit I (8 lectures)
Introduction to Programming: Computer languages, creating and running programs, Preprocessor, Compilation process, role of linker, idea of invocation and execution of a programme. Algorithms: Representation using flowcharts, pseudocode. Introduction to C language: Basic structure of C programs, process of compiling and running a C program, tokens, keywords, identifiers, constants, strings, special symbols, variables, data types, I/0 statements. Interconversion of variables.
Unit II (8 lectures)
Basics of Number Systems: Introduction to Number Systems, Types of Number Systems (Binary, Decimal, Octal, Hexadecimal), Conversion Between Number Systems, Signed and Unsigned Numbers: Representation of negative numbers (Sign-magnitude, 1’s complement, 2’s complement) Operators and expressions: Operators, arithmetic, relational and logical, assignment operators, increment and decrement operators, bitwise and conditional operators, special operators, operator precedence and associativity, evaluation of expressions, type conversions in expressions. Control structures: Decision statements; if and switch statement; Loop control statements: while, for and do while loops, jump statements, break, continue, goto statements.
Unit III (8 lectures)
Arrays: One dimensional array, declaration and initialization of one dimensional arrays, two dimensional arrays, initialization and accessing, multi dimensional arrays. Functions: User defined and built-in Functions, storage classes, Parameter passing in functions, call by value, Passing arrays to functions: idea of call by reference, Recursion. Strings: Arrays of characters, variable length character strings, inputting character strings, character library functions, string handling functions.
Unit IV (8 lectures)
Pointers: Pointer basics, pointer arithmetic, pointers to pointers, generic pointers, array of pointers/ returning pointers, Dynamic memory allocation. Pointers to functions. Pointers and Strings. Structures and unions: Structure definition, initialization, accessing structures, nested structures, arrays of structures, structures and functions, self referential structures, unions, typedef, enumerations.
Textbooks
- Balagurusamy, E. (2019). Programming in ANSI C (8th ed.). McGraw Hill Education.
- Kanetkar, Y. (2018). Let Us C (17th ed.). BPB Publications.
- Kernighan, B. W., & Ritchie, D. M. (1988). The C Programming Language (2nd ed.). Prentice Hall. (Known as K&R, the classic authoritative book on C)
References
- Engineering Problem Solving With C by Delores M. Etter, Pearson, 2013. Problem Solving and
- Program Design in C by Jeri R. Hanly and Elliot B. Koffman, Pearson, 2016.
- Venugopal, K. R., & Prasad, S. R. (2007). Mastering C. Tata McGraw Hill.
- Das, S. (2008). The C Programming Language. BPB Publications.
- Morris Mano, M. (2017). Digital Logic and Computer Design (4th ed.). Pearson Education.
- Rajaraman, V. (2010). Fundamentals of Computers (5th ed.). PHI Learning.
- Gottfried, B. S. (1996). Programming with C (2nd ed.). Schaum’s Outline Series, McGraw-Hill.
- Kochan, S. G. (2005). Programming in C (3rd ed.). Sams Publishing.