i have 2 text files in.text , out.text . read them in unsigned char ** , in each element of array stores data length t=32 bellow code char *filename = "in.text"; file *stream; int numpackets = 10; int t = 32; // length of each packets unsigned char **packetsin; fopen_s(&stream, filename, "rb"); fseek(stream, 0, seek_set); (int = 0; < numpackets; i++) { fread(packetsin[i], 1, t, stream); } fclose(stream); in same manner way, can obtain packetsout above code filename = "out.text"; file *streamout; numpackets = 10; t = 32; // length of each packets unsigned char **packetsout; fopen_s(&streamout, filename, "rb"); fseek(streamout, 0, seek_set); (int = 0; < numpackets; i++) { fread(packetsout[i], 1, t, streamout); } fclose(streamout); i want count how many different packet in packetsin , packetout (each of them has 10 packets, compare first packet in packetsin , first packet in packe