#include "iostream.h"
#include "conio.h"
void main()
{ float *x1,y, *x2;
clrscr();
y = 13.45;
x1 = &y; /* Alamat dari y disalin ke variabel x1 */
x2 = x1; /* Isi variabel x1 disalin ke variabel x2 */
cout<<"Nilai variabel y = "<<y<< " ada di alamat "<< x1<<"\n";
cout<<"Nilai variabel y = "<<y<< " ada di alamat "<< x2<<"\n";
getch();
}
0 Response to "Operasi Penugasan Pointer"
Posting Komentar