Moon unicode \u1f31x

Dear all,

I’m trying to print moon unicodes \u1f311-\u1f318 as it can be found here

when I use
print(\u1f31x)
the output is
ix
where x is a number from 1 to 8

Can someone help how to print correctly these ‘caracters’?

I can use any other unicode for the moon phases if available sofar it works

Cheers

I don’t really know much Python but it works for me when I use U000 in front of the code.

print('\U0001f311')
print('\U0001F313')

I think for Python 2 you need an u in front of the escape \ as well.

https://charbase.com/1f311-unicode-new-moon-symbol

Hi @lasjorg
thanks fro your prompt feedback. I works!!!

I could guess it was matter of format of the unicode but couldn’t figure out how to change. I digged online obviously with wrong keywords.

Thanks a lot again!!!

cheers

1 Like