PPS (Programming for Problem Solving) using C

B. Tech. Semester – I/II (Common to all Branches)




Course Objectives:

  • To make students understand basics of parts of computers and the programming.
  • To give knowledge of basic constructs of computer programming.
  • To make students understand Recursion.
  • To impart knowledge of Basic Algorithms.

Unit I

Introduction to components of a computer system (disks, memory, processor, where a program is stored and executedoperating system, compilers etc.)Introduction to Programming ,Idea of Algorithm: steps to solve logical and numerical problemsRepresentation of Algorithm: FlowchartPseudocode with examples. ,From algorithms to programssource code, variables (with data types) variables and memory locations, Syntax and Logical Errors in compilationobject and executable code.

Unit II

Arithmetic expressions and precedence, Conditional Branching and Loops, Writing and evaluation of conditionals and consequent branching ,Iteration and loops Arrays: Arrays (1-D, 2-D), Character arrays and Strings, Functions (including using built in libraries), Parameter passing in functions, call by value, Passing arrays to functions: idea of call by reference

Unit III

Recursion: Recursion, as a different way of solving problems. Example programs, such as Finding Factorial, Fibonacci series, Ackerman function etc. Structure: Defining structures and Array of Structures, Pointers :Idea of pointers, Defining pointers, Use of Pointers in self-referential structures, notion of linked list (no implementation).

Unit IV

Basic Algorithms: Searching (Linear and binary search), Basic Sorting Algorithms (Bubble, Insertion, Quick sort), Finding roots of equations, notion of order of complexity through example.

Suggested Text Books:

  1. Byron Gottfried, Schaum’s Outline of Programming with C, McGraw-Hill
  2. E. Balaguruswamy, Programming in ANSI C, Tata McGraw-Hill

Suggested Reference Books :

  1. Brian W. Kernighan and Dennis M. Ritchie, The C Programming Language, 2nd Edition,Pearson Education.

Course Outcomes: The student will learn

  1. To formulate simple algorithms for arithmetic and logical problems.
  2. To translate the algorithms to programs (in C language).
  3. To test and execute the programs and correct syntax and logical errors
  4. To implement conditional branching, iteration and recursion.
  5. To decompose a problem into functions and synthesize a complete program using divide and conquer approach.
  6. To use arrays, pointers and structures to formulate algorithms and programs.
  7. To apply programming to solve matrix addition and multiplication problems and searching and sorting problems.
  8. To apply programming to solve simple numerical method problems, namely rot finding of function, differentiation of function and simple integration.
error: You can only copy the programs code and output from this website. You are not allowed to copy anything else.