Procedural Programming with C

Undergraduate course, University of Giresun, Department of Computer Engineering, 2023

procedural programming with c C is a powerful and versatile programming language that is used in a wide variety of applications. It is a low-level language, which means that it gives you a lot of control over your programs. This makes it ideal for performance-critical applications. C is also a portable language, which means that your programs can be easily ported to different platforms. This course will teach you the fundamentals of C programming.

Chapter 1: Introduction to C Programming

  • Origins and evolution of the C language
  • Features and benefits of using C
  • Setting up a development environment
  • Basic structure of a C program
  • Variables, data types, and operators
  • Input and output functions
  • Compilation process and execution

  • Lecture Notes [pdf]

Chapter 2: Control Flow

  • Decision-making statements (if, else if, switch)
  • Looping statements (for, while, do-while)
  • Break and continue statements

  • Lecture Notes [pdf]

Chapter 3: Arrays and Strings

  • Declaring and initializing arrays
  • Manipulating arrays: accessing, modifying, and traversing
  • String manipulation and string library functions

  • Lecture Notes [pdf]

Chapter 4: Functions

  • Function declaration, definition, and calling
  • Function parameters and return values
  • Recursive functions

  • Lecture Notes [pdf]

Chapter 5: Pointers

  • Understanding pointers and memory addresses
  • Pointer declaration and initialization
  • Pointer arithmetic
  • Dynamic memory allocation (malloc, calloc, free)

  • Lecture Notes [pdf]

Chapter 6: Structures

  • Structure declaration and initialization
  • Accessing structure members
  • Nested structures and arrays of structures

  • Lecture Notes [pdf]

Chapter 7: File Handling

  • Working with files in C
  • Opening, reading, and writing files
  • File positioning and error handling
  • File I/O using standard libraries

  • Lecture Notes [pdf]

Chapter 8: Advanced Data Types

  • Enumerations and typedef
  • Bitwise operators and bit manipulation
  • Bit fields
  • Unions

  • Lecture Notes [pdf]

Chapter 9: Preprocessor Directives

  • Macros and their usage
  • Conditional compilation
  • File inclusion and header files
  • Debugging using preprocessor directives

  • Lecture Notes [pdf]

Chapter 10: Advanced Concepts - Part 1

  • Memory management techniques
  • Function pointers and callbacks
  • Understanding static and dynamic libraries
  • Recursion: principles and applications

  • Lecture Notes [pdf]

Chapter 11: Advanced Concepts - Part 2

  • Introduction to data structures (linked lists, stacks, queues)
  • Implementation and usage of data structures
  • Introduction to algorithms (sorting, searching)
  • Time and space complexity analysis
  • Variadic functions

  • Lecture Notes [pdf]

Chapter 12: Error Handling and Debugging

  • Common C programming errors
  • Debugging techniques and tools
  • Exception handling with try-catch blocks
  • Defensive programming and error handling strategies

  • Lecture Notes [pdf]

Chapter 13: Introduction to C++ (Optional)

  • Basic differences between C and C++
  • Introduction to object-oriented programming
  • Classes, objects, and constructors
  • Basic input/output in C++

  • Lecture Notes [pdf]

Chapter 14: Project and Review

  • Individual or group project using C programming concepts
  • Review of key concepts and topics covered throughout the course
  • Q&A session and final assessment

  • Sample projects [pdf]
  • Questions and answers [pdf]
  • Multiple choice questions [pdf]