Basic Programs

If Else based Programs

Loop Based Programs

Array Based Programs

String Programs

Function Programs

Pointers Programs

Structure & File Handling Programs

Data Structure Programs

Pointer based Programs

Sample Pointer Program

#include <stdio.h>
#include <conio.h>
void main()
{
       int i = 3, *ptr ;
       ptr = &i ;    // pointer variable is storing address.
       
       //two ways to display the address
        printf("Address of i =%d ", &i) ;
        printf("Address of i =%d ", ptr) ;
      
      printf("Value of variable i = %d ", *ptr);//value can be used by using ptr (pointer variable).
      printf("value of variable i = %d ", i) ;
}

Output of the above program is as following.

Video/ C Introduction

Watch video in full size
Wordpress Social Share Plugin powered by Ultimatelysocial