Python Forum
Codes does not work - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: Codes does not work (/thread-14434.html)



Codes does not work - NatalieG - Nov-29-2018

Hello,
I just started using PyCharm and after some tries, the program just stucked at the preveous activity.
Since then, I have closed the program, restarted my computer, and still, the code does not work, and I have checked myself many times.
Adding a link to the picture for you to uderstand.
https://photos.app.goo.gl/jwDoZ8Ewi4BJtpex9


RE: Codes does not work - Larz60+ - Nov-29-2018

In the future please use code tags, not images or references to images, see: bbcode
age is a string, so must be converted to integer before comparison, so change line 3 to read:
    if int(age) > 15:



RE: Codes does not work - buran - Nov-29-2018

You have 2 open tabs (i.e. 2 open files)
Natalie Test1.py and Test.py.
You are running the former. Check this link
https://www.quora.com/How-do-I-run-Python-script-in-PyCharm
I guess you just hit the green triangle and you expect that your file Test.py will run, but you need to select it from the dropdown.

In addition your Natalie Test.py file has an error


RE: Codes does not work - NatalieG - Nov-29-2018

Yeah, you're right, tnx.