def hexDump(bytes):
for i in range(len(bytes)):<EOL><INDENT>sys.stdout.write("<STR_LIT>" % (ord(bytes[i])))<EOL>if (i+<NUM_LIT:1>) % <NUM_LIT:8> == <NUM_LIT:0>:<EOL><INDENT>print(repr(bytes[i-<NUM_LIT:7>:i+<NUM_LIT:1>]))<EOL><DEDENT><DEDENT>if(len(bytes) % <NUM_LIT:8> != <NUM_LIT:0>):<EOL><INDENT>print(string.rjust("<STR_LIT>", <NUM_LIT:11>), repr(bytes[i-len(bytes)%<NUM_LIT:8>:i+<NUM_LIT:1>]))<EOL><DEDENT>
Useful utility; prints the string in hexadecimal