I have a byte representation of a string, no idea what is the encoding, I know that b'\x04\x00\x00\x00\xf0\x9f\x90\x9f\x00' represents (fish character). Is it possible to find the encoding based on this information?
I checked  print(b'\x04\x00\x00\x00\xf0\x9f\x90\x9f\x00')  prints , so terminal knows its encoding, not me.
\xf0\x9f\x90\x9f is the UTF-8 encoded character U+1F41F FISH.
The rest are useless NUL bytes and one 0x04 EOT byte, which don't do a lot usually.
Find encoding based on input and output