What is keywords ?
Key words is a reserved word whose meaning already defined in the compiler.
There are 32 types of keywords .
1. Int
2.char
3.float
4.double
5.void
6.auto
7.register
8.return
9. Extern
10.goto
11.break
12.continue
13.do
14.switch
15.case
16.while
17.for
18.const
19.if
20.else
21.enum
22.signed
23.unsigned
24.static
25.size of
26.short
27.struct
28.union
29.typedef
30.vdatile
31.default
32.long
C language is a case sensitive language so all keywords should be written in lowercase .
In C language, a keyword is a reserved word that has a special meaning and purpose in the language. Keywords cannot be used as variable names or identifiers in a program.
Here is a list of C language keywords:
auto
break
case
char
const
continue
default
do
double
else
enum
extern
float
for
goto
if
int
long
register
return
short
signed
size of
static
struct
switch
typedef
union
unsigned
void
volatile
while
These keywords are used to define program structure, data types, loops, and other programming constructs. It is important to note that you cannot use these keywords as variable names or identifiers in your program, as they are reserved for specific purposes in the C language.
"auto": This keyword is used to define automatic variables, which are local variables that are automatically created and destroyed when a function is called and returned, respectively.
"const": This keyword is used to define constants, which are variables whose value cannot be changed during the execution of the program.
"for": This keyword is used to create a loop that iterates a fixed number of times, with a specified starting value, condition, and increment.
"if": This keyword is used to create a conditional statement that executes a block of code if a specified condition is true.
"int": This keyword is used to define integer variables, which are variables that can hold whole number values.
"Return": This keyword is used to return a value from a function to the calling program.
"size of": This keyword is used to determine the size of a variable or data type in bytes.
"while": This keyword is used to create a loop that continues to execute a block of code while a specified condition is true.
These are just a few examples of the many keywords in the C language. Each keyword has a specific purpose and is used to define different elements of a C program. It is important to understand the role and usage of each keyword to write effective and efficient C programs.

0 Comments