|Welcome to the Monastery|
Re^2: strings to number and XORby alager (Acolyte)
|on Oct 07, 2009 at 17:52 UTC||Need Help??|
Last question, then I should be done. :)
For the variable
$key = "\x4f\xcb"; How can I increment it?
I've tried directly with $key++, but that starts counting at 0, I would expect \x4f\xcc as the result.
And I've tried unpacking it. Which starts incrementing with the first number (4 in this case) and loses the rest of the data. eg 4,5,6...
I would like
0x4fcb 0x4fcc 0x4fcd ect.
UPDATE: I've found part of the problem, perl doesn't like to add numbers that aren't "numbers", this works fine as long as my bytes are in the range of ASCII numbers, but fails for values above outside of 0x30-0x39.