ANDROID APPS

C++ Pointers‎ > ‎

Pointer Example Program In C++

Poniter Variable Assign Syntax: 

pointer_vaibale = &variable; 

C++ Example Pointer Program:

#include<iostream.h> 
#include<conio.h> 
int main() 
int i=10; 
int *Ptr; 
clrscr(); 
Ptr=&i; 
cout<<"\nValue Of i :"<<i; 
cout<<"\nAddress Of i :"<<i; 
cout<<"\nValue Of Ptr :"<<Ptr; 
cout<<"\nAddress Of Ptr :"<<&Ptr; 
cout<<"\nPtr's Pointer Value:"<<*Ptr; 
cout<<"\nPtr Equal to &i :"<<*(&i));