#include <iostream>
using namespace std;
void function(int* i)
{
*i=5;
}
int main()
{
int a=2;
int *b=&a;
function(b);
cout<<*b;
return 1;
}
| CodeGuru Home | VC++ / MFC / C++ | .NET / C# | Visual Basic | VB Forums | Developer.com |
|
Results 1 to 9 of 9
Thread: Have got error pointerThreaded View
|
Click Here to Expand Forum to Full Width |