Tribhuvan University

Institute of Science and Technology

Bachelor of Science in Computer Science and Information Technology

Course Title: C Programming

Course no: CSC115

Semester: I

Nature of course: Theory + Lab

Full Marks: 60 + 20 + 20

Pass Marks: 24 + 8 + 8

Credit Hours: 3

Course Description : This course covers the concepts of structured programming using C programming language.

Course Objective : This course is designed to familiarize students to the techniques of programming in C.

Course Contents:
Laboratory Works:

This is the first "programming" course in B.Sc.CSIT. It builds the foundation on how to write a program using any high level language. Hence, this course requires a lot of programming practice so that students will be able to develop good logic building and program developing capability which is essential throughout the B.Sc.CSIT course and thereafter. 20% of the total marks is assigned from the practical. Some important contents that should be included in lab exercises are as follows:

Unit 1: (2 Hrs)

Create, compile, debug, run and test simple C programs

Unit 2,3,4: (5 Hrs)

Using different data types available in C, perform arithmetic operations in C, perform formatted input/output operations, perform character input/output operations.
Using relational operator, logical operator, assignment operator, ternary operator, and other operators. Evaluation of Expression to check operator precedence and associativity.

Unit 5: (6 Hrs)

Create decision making programs using control statements like; if, if..else, if..else ladder, nested if, and switch cases.

Create programs using loops (for, while, do while, nested loops) and realize the differences between entry controlled and exit controlled loops.

Unit 6: (6 Hrs)

Create, manipulate arrays and matrices (single and multi-dimensional), work with pointers, dynamically allocate/de-allocate storage space during runtime, manipulate strings (character arrays) using various string handling functions.

Unit 7: (6 Hrs)

Create user-defined functions with/without parameters or return type, create recursive functions, use function call by value and call by address, work with automatic, global and static variables.

Unit 8: (5 Hrs)

Create and use simple structures, array of structures, nested structure. Passing structure and array of structure to function, concept of pointer to structure

Unit 9: (6 Hrs)

Create programs that addresses pointer arithmetic, pointers and arrays, pointer and character strings, pointers and functions, pointer and structure, and dynamic memory allocation.

Unit 10: (5 Hrs)

Create files that address random access and input/output operations in file, create files to keep records and manipulation of records etc.

Unit 11: (4 Hrs)

Create graphics program that address some basic functions of graphics.h header file, e.g. line(), arc(), circle(), ellipse(), floodfill(), getmaxx(), getmaxy() etc.

Note: Motivate students to create small project work integrating all of the above concepts.


Text Books:
  • Byron Gottfried: "Programming with C," , Second Edition, McGraw Hill Education.
  • Herbert Schildt, C The Complete Reference, Fourth Edition, Osborne/McGraw-Hill Publication.
Reference Books:
  • Paul Deitel, Harvey Deitel, C: How to Program, Eighth Edition, Pearson Publication.
  • Al Kelley, Ira Pohl: "A Book on C", Fourth Edition, Pearson Education.
  • Brian W. Keringhan, Dennis M. Ritchiem, The C programming Language, Second Edition, PHI Publication.
  • Ajay Mittal, Programming in C: A Practical Approach, Pearson Publication
  • Stephen G. Kochan, Programming in C, CBS publishers & distributors.
  • E. Balagurusamy, Programming in ANSI C, Third Edition, TMH publishing