Write a C++ program the includes the declaration statements int num, count;
long date;
float yield;
double price;
Have the program use the address operator and the cout object to display the addresses that correspond to each variable.
#include<iostream>
using namespace std;
int main()
{
int num, count;
long date;
float yield;
double price;
cout<<"num adress = "<<&num<<endl;
cout<<"count adress = "<<&count<<endl;
cout<<"date adress = "<<&date<<endl;
cout<<"yield adress = "<<&yield<<endl;
cout<<"price adress = "<<&price<<endl;
return 0;
}
Need a fast expert's response?
Submit order
and get a quick answer at the best price
for any assignment or question with DETAILED EXPLANATIONS!
Learn more about our help with Assignments:
C++