I need to convert an int array like this...
int[] myInts = {
99999,
9999,
99999,
1,
1234567890,
24385933,
99
};
...as efficiently as possible into a byte[]
so it can be saved on an NFC tag.
I have seen this very similar question from which I have tried the two the answers (here and here), but the byte arrays they create both have a length of 28.
Unfortunately, that's no good for me as I need to create a byte[] with a maximum length of 16 (as the tag this data has to be saved on is a MIFARE Ultralight EV1).
Is there any other approach I could try in order to convert myInts
to a byte[16]
?