Problem Solving Using C Programming Exhaustive Study Guide

Course Overview and Objectives

  • Course Code: 25CSI11
  • Institution: Shree Venkateshwara Hi-Tech Engineering College (Autonomous)
  • Course Title: Problem Solving Using C Programming
  • Target Audience: Common to B.E. / B.Tech. all Branches
  • Credit Structure (L T P C): 30243\,0\,2\,4
  • Primary Objectives:
    • To learn how to think algorithmically to solve a problem.
    • To gain knowledge of fundamental programming concepts in C programming.
    • To explore the basic concepts of arrays and pointers.
    • To learn the concepts of functions and structures.
    • To gain proficiency in file handling techniques.

Unit I: Computational Thinking

  • Total Duration: 99 Periods
  • Overview of Computational Thinking: Detailed exploration of key techniques and the central philosophy of problem-solving through computation.
  • Software Development Life Cycle (SDLC): Provides an overview of the stages involved in software creation from conception to maintenance.
  • Algorithmic Thinking Elements:
    • Sequence: The linear execution of steps.
    • Selection: Fundamental decision-making logic.
    • Repetition: The use of loops to repeat operations.
  • Representation Tools:
    • Flow Chart: Visual representation of algorithms.
    • Flow Algorithm Tool: Overview of software tools for flow design.
    • Pseudo-code: Structural conventions for defining algorithms.
  • Introduction to Programming Languages: A broad overview of how languages communicate instructions to computers.

Unit II: Basics of C Programming

  • Total Duration: 99 Periods
  • Foundations of C:
    • Introduction to the C language and its historical context.
    • Formal structure of a C program.
    • The process of Compiling, Executing, and Debugging code.
  • Language Syntax Elements:
    • Character Set: The valid characters recognized by C.
    • Tokens: Smallest individual units in a program.
    • Identifiers: Naming conventions for variables and functions.
    • Data Types: Categorization of data (int, char, float, etc.).
    • Variable Constants: Proper use of fixed values.
  • Operations and Control:
    • Evaluating Expressions: How C processes mathematical and logical statements.
    • Type Conversion: Implicit and explicit casting between data types.
    • Input and Output: Using standard libraries for I/O operations.
    • Decision Control and Looping Statements: Implementation of if-else, switch, for, while, and do-while constructs.

Unit III: Arrays and Pointers

  • Total Duration: 99 Periods
  • Array Fundamentals:
    • Introduction to the concept of contiguous memory allocation.
    • Declaration and initialization of Single Dimensional (1D) Arrays.
    • Common Array Operations (insertion, deletion, traversal).
  • Advanced Array Concepts:
    • Declaration and initialization of Two-Dimensional (2D) Arrays.
    • Understanding Multidimensional structures.
  • Strings:
    • Declaring and initializing string variables.
    • Methods for Reading and Writing strings.
    • Standard String Operations (Built-in and manual).
    • Concept of an Array of Strings.
  • Pointers:
    • General introduction to memory addresses and pointer variables.
    • Pointer Operators: Use of address-of (&&) and indirection (*) symbols.
    • Pointer Arithmetic: Calculations involving memory addresses.
    • Integration: The relationship between arrays and pointers, and the implementation of arrays of pointers.

Unit IV: Functions and Structures

  • Total Duration: 99 Periods
  • Functions:
    • Definition and Types of Functions.
    • Core Elements of a function declaration and definition.
    • Parameter Passing: Detailed study of Pass by value versus Pass by reference.
    • Recursion: Implementing self-referential function calls.
    • Storage Classes: Use of auto, register, static, and extern to manage variable scope and lifetime.
  • User-Defined Data Types:
    • Introduction to Structures.
    • Declaring and Defining Structure Variables.
    • Accessing Individual Structure Members.
    • Structure Initialization techniques.
    • Complex Structures: Nested structures and Arrays of structures.
    • Keywords: Use of typedef for type aliasing and the concept of Unions.

Unit V: File Processing

  • Total Duration: 99 Periods
  • File Management:
    • Introduction to persistent data storage.
    • Syntax and logic for using files in C.
    • Techniques for reading data from files and writing data to files.
  • System Interaction:
    • Error Handling: Managing issues during file operations to prevent crashes.
    • Command Line Arguments: Passing parameters to the main function at the time of program execution.

Practical Exercises

  • Total Lab Duration: 3030 Periods
  • List of Exercises:
    1. Implementation of algorithm, flowchart, and pseudo-code to solve electricity billing.
    2. Implementation of algorithm, flowchart, and pseudo-code to solve retail shop billing.
    3. Implementation of if, if-else, nested if, and switch statements.
    4. Implementation of while, do-while, and for loops.
    5. Implementation of sorting and searching algorithms.
    6. Implementation of one-dimensional array, passing array to functions, and array operations.
    7. Implementation of programs for various string operations like "copy", "finding length", "compare", "concatenate" with built-in library functions.
    8. Implementation of the same string operations (copy, length, compare, concatenate) without built-in library functions.
    9. Implementation of pointer operators, call by reference, and pointers with array.
    10. Implementation of function calls, recursion, and call by value.
    11. Implementation of structure and nested structure.
    12. Implementation of array of structures.
    13. Implementation of file operations.
    14. Implementation of file to read NN characters using file functions.

Course Outcomes (COs)

Upon successful completion, students will be able to:

  • CO 1: Construct algorithmic solutions for a given computational problem.
  • CO 2: Demonstrate the understanding of fundamental concepts of C programming.
  • CO 3: Utilize appropriate concepts of arrays and pointers to solve the programming problems effectively.
  • CO 4: Apply concepts of functions and structures in C programming.
  • CO 5: Implement file I/O operations to store and retrieve data from files.

Reading Materials and Resources

Text Books:

  1. Reema Thareja, "Programming in C", Oxford University Press, Second Edition, 20232023.
  2. Kernighan, B.W and Ritchie, D.M, "The C Programming language", Second Edition, Pearson Education, 20232023.

Reference Books:

  1. Paul Deitel and Harvey Deitel, "C How to Program with an Introduction to C++", Eighth edition, Pearson Education, 20232023.
  2. Yashwant Kanetkar, "Let us C", 17th Edition, BPB Publications, 20232023.
  3. Byron S. Gottfried, "Schaum's Outline of Theory and Problems of Programming with C", McGraw-Hill Education, 20242024.
  4. Pradip Dey, Manas Ghosh, "Computer Fundamentals and Programming in C", Second Edition, Oxford University Press, 20222022.
  5. Anita Goel and Ajay Mittal, "Computer Fundamentals and Programming in C", 1st Edition, Pearson Education, 20242024.

E-Resources:

  1. Tutorial Point: https://www.tutorialspoint.com/cprogramming/index.htm
  2. GeeksforGeeks: https://www.geeksforgeeks.org/c-programming-language/

COs, POs, & PSOs Mapping Matrix

Correlation Levels: 1 - Low, 2 - Medium, 3 - High, '-' - No correlation

COPO1PO2PO3PO4PO5PO6PO7PO8PO9PO10PO11PO12PSO1PSO2PSO3
CO122223322222211112211111122-33
CO2331122223322112211111122-3322
CO3332222113311111122-3333222222
CO41122112211223322221122-221133
CO5222233222211333333222222223322
AVG2.22.22.42.42.42.41.21.2221.21.21.31.31122112.82.82.42.41.81.82.22.222