National Institute of Technology Rourkela

राष्ट्रीय प्रौद्योगिकी संस्थान राउरकेला

ଜାତୀୟ ପ୍ରଯୁକ୍ତି ପ୍ରତିଷ୍ଠାନ ରାଉରକେଲା

An Institute of National Importance

Syllabus

Course Details

Subject {L-T-P / C} : CS1000 : Basic Programming { 1-0-2 / 2}

Subject Nature : Practical

Coordinator : Prof. Ramesh Kumar Mohapatra

Syllabus

Lecture 1: Introduction to C programming: Role of Compiler, Interpreter, Assembler. The Structure of a programming language. Writing and executing a Program. Program Debugging. . Assignments on creating, editing, executing, and debugging simple C programs.

Lecture 2: Data Types, Variables, Operators, Pre-processor Directives Input and Output Operators, Reading/Writing Characters, Formatted input/output Function. Assignments on operators for laboratory practice.

Lecture 3: Control Statement: IF.....ELSE Statement, IF......ELSE ladder, Nesting of IF.....ELSE Statements. Assignment on Control Statement for laboratory practice.

Lecture 4: Looping Control Statements: do-while, while, and for Statements. Branch control statements: Switch case, break, continue, goto statements. Assignment on Looping Control Statements for laboratory practice.

Lecture 5: Introduction to Array: One Dimensional Array, Two-Dimensional Array, Multi Dimensions Arrays. String Handling: Reading String from Terminal, Writing String to Screen. Assignments on array for laboratory practice.

Lecture 6: Pointers in C: Understanding Pointers, Pointer expressions, Pointer and Arrays, Pointers and Character String, Assignments on pointers for laboratory practice.

Lecture 7: Function: String Handling Functions. Function in C: Function Basics, Advantage of Function, Recursion, Variable Storage Classes, Variable arguments Function. Pointers to Functions. Assignments on functions for laboratory practice.

Lecture 8: Defining a Structure, Advantage of Structure, Size of Structure, Arrays of Structures, Structures and Functions, Defining Unions. Assignments on structure and Union for laboratory practice.

Lecture 9: Introduction to Dynamic Memory Allocation, malloc(), calloc(), realloc(), free(). Assignments on Dynamic Memory Allocation for laboratory practice.

Lecture 10: File Management in C: Introduction to File Management, Opening/Closing a File, Input/Output operations on Files, Error Handling During I/O Operations, Command Line Arguments. Pre-processor: Macro Substitution, File Inclusion, Computer Control Directives. Assignments on File Handling for laboratory practice.

Course Objectives

  • To introduce students to the basic knowledge of programming fundamentals of basic programming language. Learn to write, edit, compile, debug, correct, recompile and run a program on a computer.
  • The concept of algorithm and creating the ability to analyze a problem, develop an algorithm to solve it.
  • To impart the concepts like operators, looping, array, functions, pointers, structure, union, and file handling.
  • The program coding techniques for the implementation of various real life problems.

Course Outcomes

The course aims to provide exposure to problem-solving through programming. It aims to make the student understand the basic concepts of a programming language. After completing this laboratory course, a student will be able to: <br />CO1: know the steps involved in compiling, linking, and debugging any code written on a specific language. <br />CO2: understand the basic concepts of any programming language such as keyword, identifiers, header files, and the methods of iteration or looping and branching, etc. <br />CO3: know the use of pointers and different data-structures like arrays, structures, union, etc. <br />CO4: understand various library and user-defined functions along with their declaration and definition. <br />CO5: understand the concepts of file handling and its applications.

Essential Reading

  • Brian W. Kernighan and Dennis M. Ritchie, The C Programming Language, Pearson Education India
  • Herbert Schildt, C: The Complete Reference, McGraw Hill Education

Supplementary Reading

  • R.Geoff Dromey, How to Solve it by Computer, Prentice-Hall
  • Byron Gottfried, Schaum's Outline of Programming with C, McGraw-Hill