mercredi 2 septembre 2020

How to compare pointer value in C++

int* fun(int* p2)
{
int* p1= NULL;
p1 = CCERT((float*)n,a);
if(*p1 == *p2)
{
cout<<"True";
} 
}

Is it correct way to compare value of p1 and p2? I want to compare values of p1 and p2. please suggest some way.

Aucun commentaire:

Enregistrer un commentaire