Re: Adding hex to byte array
Yeah, the address is already in hex. There is no good reason to turn hex into a string unless you want to display it. You aren't displaying it, so don't turn it into a string at all. That just wastes time and makes your life more difficult. Hex is nothing but a certain way of representing a binary number. All numbers in computers are binary. You can represent them as decimal or you can represent them as Hex. We generally learn decimal, but hex makes more sense for representing a binary number. However, if you had a function that returned an Integer and you wanted to add 48 to it, would you take the integer, convert it to a string, convert it back to a number, then add 48? Not too likely, but that's exactly what you are doing in your code.