I'm writing a book for beginners that shows the zodiac signs when you get older.
if you write
Please enter the year of your birth in 4 digits:
and enter the year
If it's a book, your zodiac sign should say ~, but is there something wrong with the way you wrote it?❓python python3
If you are using Python 3, this code should print correctly.However, Python 2 prints a string with a lot of backslashes escaped, as shown in the questionnaire.This is related to a change in the way strings are encoded in the program starting with Python 3.0.
So please check your Python version first.For example, you can verify this by entering the following command at the terminal:
If Python 2.x is installed, that is the reason.There are several solutions.
python3command exists, use it instead of the
pythoncommand.This is a command to run Python 3.x series.
© 2022 OneMinuteCode. All rights reserved.