条件が満たされた場合に「スペース」または「0」を追加できるように、既存のバイト配列を変更するにはどうすればよいですか
for example ::
last 2 byte Hex value if E0 in decimal is -32
byte1 [] = [48, 16, 6, 11, 43, 6, 1, 2, 1, 69, 1, 2, 1, 6, 9, 4, 1, -32]
last 1byte 101=e 48=0
byte2[]=[48, 17, 6, 11, 43, 6, 1, 2, 1, 69, 1, 2, 1, 6, 9, 4, 2, 101, 48]
バイト配列の最後のインデックスが2バイトの16進数か1バイトかを知るにはどうすればよいですか。これが16進数の場合、バイト配列に「0」または「スペース」を追加する必要があります
In precise : the last character need to be checked
byte b = byte1[18]
check this whether it's one byte or 2 byte if it come as "e0" then 2 byte if it's come as "0" then modify the byte array to contain extra "0"