Re:Hexyl: A command-line hex viewer
by hwj on Wednesday January 09, 2019 @10:39AM
(#18865493)
What are line numbers in context of a binary?
[ Parent
| on HN ]
Right, I was being a bit loose there. I meant something like how `xxd` displays the number of bytes up to the current output row. Just something to give context of where you are in the file.
00006980: 0000 0000 0000 0000 0000 0000 0000 0000You can quickly find position of byte number X using:
line number = floor(X/(bytes/line)) + 1
column offset = X % (bytes/line) + 1
Or it could just print byte numbers instead of line numbers.
Addresses.