How to compare two images using byte arrays

Using == will compare the object references if not overridden.

Since these are two different byte[] objects, the references are different.

You need to compare the byte[] objects item by item in order to confirm that they are identical. You can use SequenceEquals in this case.

Leave a Comment