Complete C Programming Definitions (100+ Terms)
Preprocessor
Processes directives like #include, #define before compilation.
Macro
Code snippet replaced before compilation. Defined using #define.
Header File
Contains function declarations and macro definitions, e.g., stdio.h.
Include Directive
Used to include header files using #include.
Conditional Compilation
Using #ifdef, #ifndef, #endif for compiling selective code.
Define Directive
Used to define macros or constants using #define.
Undef Directive
Used to undefine a macro using #undef.
Pragma Directive
Used to issue special commands to the compiler using #pragma.
Variable
Named storage for data, with a data type.
Constant
Fixed value that does not change during execution.
Data Type
Specifies type of data (int, float, char, etc.).
Integer
Whole number data type (int).
Float
Decimal number data type.
Character
Single character data type (char).
Void
Indicates no return or no parameters.
Boolean
Represents true or false (typically 0 and 1 in C).
Format Specifier
Defines data type for I/O (e.g., %d, %f).
Arithmetic Operators
+, -, *, /, % used in mathematical operations.
Relational Operators
==, !=, >, <, >=, <= used to compare values.
Logical Operators
&&, ||, ! used for logical conditions.
Bitwise Operators
&, |, ^, ~, <<, >> used for bit-level operations.
Assignment Operators
=, +=, -=, *=, /= assign values.
Increment Operator
++ increases a variable's value by 1.
Decrement Operator
-- decreases a variable's value by 1.
Ternary Operator
?: used for conditional expressions.
Comma Operator
Evaluates multiple expressions, returns last value.
Sizeof Operator
Returns the size of a data type or variable.
Type Casting
Converts one data type to another.
If Statement
Conditional statement for decision making.
Else Statement
Defines alternative block if 'if' fails.
Else If
Checks multiple conditions.
Switch Statement
Multi-way branch statement.
Case
Defines individual conditions in switch.
Default
Defines fallback in switch.
While Loop
Repeats a block while a condition is true.
Do While Loop
Executes at least once before checking condition.
For Loop
Compact loop with initialization, condition, and increment.
Break Statement
Exits loop or switch prematurely.
Continue Statement
Skips current iteration of loop.
Goto Statement
Jumps to a labeled statement.
Label
Named location used with goto.
Function
Reusable block of code for performing a task.
Function Declaration
Tells the compiler about a functions name, return type, and parameters.
Function Definition
Actual code block of the function.
Function Call
Invokes a defined function.
Return Statement
Returns a value from a function.
Recursion
Function calling itself to solve smaller sub-problems.
Parameter
Variable listed inside function's parentheses.
Argument
Value passed to a function.
Array
Collection of elements of the same data type.
Multidimensional Array
Array of arrays (e.g., matrix).
String
Array of characters ending with null character '\0'.
String Library
Functions like strlen(), strcpy(), strcat().
Pointer
Stores address of another variable.
Dereferencing
Accessing value using * operator.
Pointer Arithmetic
Operations like ++, -- on pointers.
NULL Pointer
Pointer initialized with zero address.
Dangling Pointer
Pointer pointing to a deallocated memory.
Void Pointer
Pointer without a data type.
Pointer to Pointer
Double indirection, pointer holding another pointers address.
Function Pointer
Pointer pointing to a function.
Array of Pointers
Array that stores multiple pointer values.
Structure
User-defined data type grouping different data types.
Nested Structure
Structure inside another structure.
Union
Similar to structure, but shares memory among members.
Bit Field
Allows storing data in specific number of bits.
Typedef
Gives new names to existing types.
Enumeration
Defines a list of integer constants using enum.
Static Memory Allocation
Memory allocated at compile time.
Dynamic Memory Allocation
Memory allocated during runtime using malloc(), calloc().
malloc()
Allocates memory block and returns pointer.
calloc()
Allocates memory block and initializes to zero.
realloc()
Resizes previously allocated memory block.
free()
Deallocates previously allocated memory.
File
Used for data storage in external files.
fopen()
Opens a file in specified mode.
fclose()
Closes an open file.
fgetc()
Reads a character from file.
fputc()
Writes a character to file.
fgets()
Reads a line from file.
fputs()
Writes a line to file.
fprintf()
Writes formatted output to file.
fscanf()
Reads formatted input from file.
feof()
Checks end of file.
Command Line Arguments
Pass arguments to main() via command line.
main() Function
Starting point of every C program.
Compilation
Process of converting C code to machine code.
Linking
Combining object files into executable.
Debugger
Tool to test and debug code.
Compiler
Translates source code to machine code.
Interpreter
Executes code line-by-line (C uses compilers).
Inline Function
Suggests compiler to insert code in place of function call.
Volatile Keyword
Tells compiler variable may change unexpectedly.
Const Keyword
Declares variable as constant.
Extern Keyword
Declares a global variable defined elsewhere.
Static Keyword
Preserves variable value between function calls.
Register Keyword
Suggests storing variable in CPU register.