Basic

Switch Case

Goto

Operators

if Statement

Nested if

While Loop

For Loop

Array

Patterns

Excersises


Special Operators in C Program


The following operators are called special operators in c program.

Operator Description
sizeof Used to get the size of the variable.
& Used to get the address of the variable.
* Used to point the other variable.

Example : pgm.c

#include<stdio.h>
int main(){
    int a=482;
    long int x=10;
    float b=10;
    char c=1;
    int *add=&a;
    printf("\nSize of Integer: %d",sizeof(a));
    printf("\nSize of Long   : %d",sizeof(x));
    printf("\nSize of Float  :%d",sizeof(b));
    printf("\nSize of Character : %d",sizeof(c));
    printf("\nAddress of Variable : %d",&a);
    printf("\nValue of a : %d",*add);
    return 0;
}

Output:

Size of Integer : 4
Size of Long : 4
Size of Float : 4
Size of Character : 1
Address of Variable : 6422020
Value of a : 482