I was looking at this exercise and it was mentioned that the string \x1AL\xD23k\xCA\x1D\xD7
consists of 8 bytes. However, I fail to see how there are 8 bytes in the string. Shouldn't there be 7 bytes instead since \x1A
would represent 1 byte and any character without \x
is a byte on its own?
Asked
Active
Viewed 389 times
-2
![](../../users/profiles/98538.webp)
Anders
- 64,406
- 24
- 178
- 215
![](../../users/profiles/124200.webp)
Lew Wei Hao
- 429
- 5
- 13
-
2I'm not sure how this is a security question – schroeder Sep 21 '16 at 20:40
1 Answers
0
\x1A
,L
,\xD2
,3
,k
,\xCA
,\x1D
,\xD7
. 8 bytes.
The convention is that \x
is followed by exactly two characters base 16 that together denote the byte value. You might want to check out C escape sequeces.
![](../../users/profiles/95381.webp)
Arminius
- 43,922
- 13
- 140
- 136