CodeSutraHub

Complete List of 32 Keywords in C Language

The C language contains a total of 32 keywords. These are reserved words that have special meaning in a program. Understanding these keywords makes learning programming much easier.

Important Points About Keywords

  • Keywords are reserved words: They cannot be used as variable names.
  • Case-sensitive: int, Int, and INT are different.
  • Control flow keywords: if, else, switch, for, while, do, break, continue, goto.
  • Data type keywords: int, float, double, char, void, long, short, signed, unsigned.
  • Storage class keywords: auto, static, extern, register.
  • Special keywords: sizeof, typedef, volatile, return.

List of Keywords in C Language

Keyword Meaning / Purpose
autoAutomatic storage class
breakUsed to exit from a loop or switch statement
caseUsed for branching in switch statement
charUsed to declare a character data type
constUsed to declare a constant (fixed value)
continueSkips the remaining part of the current loop iteration
defaultDefault branch in switch statement
doUsed in do-while loop
doubleUsed to declare double-precision floating-point data type
elseAlternative block of if statement
enumUsed to declare enumeration type
externUsed to declare global variables
floatUsed to declare floating-point data type
forUsed to create loop structure
gotoUsed to jump to a labeled statement
ifUsed to write decision-making statements
intUsed to declare integer data type
longUsed to declare long integer data type
registerUsed to store variable in CPU register
returnUsed to return a value from a function
shortUsed to declare short integer data type
signedUsed to declare signed data type modifier
sizeofUsed to find the size of a data type or variable
staticStatic storage class
structUsed to declare a structure
switchUsed to create multi-way branching statements
typedefUsed to define a new data type name
unionUsed to declare union for shared memory storage
unsignedUsed to declare unsigned data type modifier
voidSpecifies no return value or empty type
volatilePrevents compiler from optimizing a variable
whileUsed to create a loop statement