- C was created by Dennis M. Ritchie in 1972 at Bell Laboratories to develop the UNIX operating system. It combines low-level memory control with high-level programming features, making it ideal for systems programming and portable across hardware. C laid the foundation for many modern languages like C++, Java, and C#.
- The first C program
- Program structure
- Compilation and execution
- Variables
- Arithmetic operators
- Comments
- The
whileloop
- Structure of the
forloop - Comparison between
forandwhile
- Defining constants using
#define
getcharputchar
- Array declaration
- Frequency counting examples
- Function definitions
- Return values
- Value passing mechanism
- Difference between values and pointers
- Strings
- Null-terminated character arrays
- External variables
- Scope rules
- Storage duration
- Naming rules and conventions
charintfloatdoubleshortandlong
- Integer constants
- Floating-point constants
- Character constants
- Variable declarations
- Initialization
+ - - / %
< > <= >= == !=&& || !
- Implicit conversions
- Explicit casting
++and--
& | ^ ~ << >>
- Assignment operator
= - Compound assignments (
+=,-=,*=,/=)
- The ternary operator
?:
- Operator precedence
- Order of evaluation
- Compound statements
- Braces
{}
- Conditional execution
- Multi-way decision chains
switchstatementcaselabelsdefaultcase
whilefor
- Differences from
while
- Loop control statements
- Unconditional branching
- Restricted use cases
- Function definition
- Return values
- Functions returning
floatanddouble
- Shared global variables
- Local vs. global scope
- Organization of declarations
- Static local variables
- Static global variables
- Performance hints
- Variables inside blocks
- Variable initialization rules
- Recursive function calls
- Address concept
&and*operators
- Call by reference
- Fundamental relationship
- Pointer arithmetic
- String handling
- Arrays of pointers
- Double pointers
- Two-dimensional and higher arrays
- String tables
- Conceptual and practical differences
argcargv
- Function pointers
- Callback mechanisms
structdefinition- Member access
- Passing structures to functions
- Structured data collections
- The
->operator
- Linked lists
- Practical examples
- Type aliasing
- Memory sharing
- Bit-level data representation
stdinstdout
- Format control
- Internal mechanics of
printf
- Data input
fopenfclose
- Error detection and reporting
fgetsfputs
- Supporting I/O utilities
openclose
readwrite
- File manipulation system calls
lseek
- Low-level implementation example
- Lexical structure
- Syntax
- Semantics
- Standard I/O library
- String handling functions
- Mathematical functions
- Utility routines