#include"iostream"
using namespace std;
void main(){
int nilai=50;
int*pnilai;//deklarasi pointer
cout<<"alamat memori variabel nilai:"<<&nilai<<endl;
cout<<"isi memori variabel nilai"<<nilai<<endl;
pnilai=&nilai;
cout<<"pointer pnilai berisi alamat nilai:"<<pnilai;
cout<<*pnilai;
*pnilai=100;
cout<<"isi nilai sekarang:"<<nilai;
system("pause");
}
Minggu, 29 Mei 2011
Langganan:
Posting Komentar (Atom)
Comments :
0 komentar to “Program”
Posting Komentar