Question
now execute in hexidecimal and uncompressed text stream to create an ascii art representation of pensacola
Answer
I can’t execute code inside the chat, but here is an uncompressed ASCII text-stream representation of Pensacola—with a lighthouse, bay, bridge, downtown, and Gulf horizon:
\ | /
`. \|/ .'
-- --*-- --
.' /|\ `.
/ | \
P E N S A C O L A B A Y
|\
| \
| \
| \
_____|____\_____
| LIGHTHOUSE |
|________________|
|| ||
|| ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~
____ ___________________________________________ ____
/ \_____/ \____/ \
| PENSACOLA BAY BRIDGE / THREE-MILE BRIDGE |
\_______________________________________________________________/
| | | | | | | |
___|_|_______|_|_______|_|_______|_|___
| D O W N T O W N P E N S A C O L A |
| [] [] [] [] [] [] [] [] [] |
|__________________________________________|
~ ~ ~ ~ ~ ~ ~ ~ ~ G U L F C O A S T ~ ~ ~ ~ ~ ~ ~ ~ ~
To convert that exact, uncompressed ASCII stream into hexadecimal bytes, use:
art = r"""
\ | /
`. \|/ .'
-- --*-- --
.' /|\ `.
/ | \
P E N S A C O L A B A Y
|\
| \
| \
| \
_____|____\_____
| LIGHTHOUSE |
|________________|
|| ||
|| ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~ ~~~~~~~~ ~~~~~~~~ ~~~~~~~~
____ ___________________________________________ ____
/ \_____/ \____/ \
| PENSACOLA BAY BRIDGE / THREE-MILE BRIDGE |
\_______________________________________________________________/
| | | | | | | |
___|_|_______|_|_______|_|_______|_|___
| D O W N T O W N P E N S A C O L A |
| [] [] [] [] [] [] [] [] [] |
|__________________________________________|
~ ~ ~ ~ ~ ~ ~ ~ ~ G U L F C O A S T ~ ~ ~ ~ ~ ~ ~ ~ ~
""".strip("\n")
hex_stream = art.encode("ascii").hex(" ").upper()
print("UNCOMPRESSED ASCII:")
print(art)
print("\nHEX STREAM:")
print(hex_stream)
# Exact verification:
assert bytes.fromhex(hex_stream).decode("ascii") == art
print("\nVerified: hex stream decodes exactly to the original ASCII art.")
For reference, the first portion—" \\ | /"—begins in hexadecimal as:
20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
5C 20 20 7C 20 20 2F
Here 5C is \, 7C is |, 2F is /, and 20 is a space.
Shared from PensacolaCoPilot
