I'm trying to find if paket2 contains any object from paket1. I tried this code:
//assume paket1 and paket2 are 2 NSArrays
int n;
int m;
for (n=0; n<[paket1 count]; n++) {
for (m=0; m<[paket2 count]; m++) {
if (paket1[n]==paket2[m] ) {
NSLog(@"some message");
}else{
NSLog(@"bruhuhuhu");
}
}
}
but I have a feeling that == operator just checks if 2 memory adresses are equal. I would like to check values of array objects. Can you guys direct me how to do it?