#π Input in python
61 messages Β· Page 1 of 1 (latest)
@ripe cape
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
I honestly donβt see what the issue is, that should work
literally started like 7 minutes ago
Same, like what? Did you try running that again?
ive tried multiple time
when it asks for the name
i type it out
then hit enter
then the red stuff appears
i dont even think its an error
it makes no sense
tty doing it
a = str(input('sdfsdf: '))
print(a)
python 2.7?
Ah
it says bottom right
you definitely have python 2.7, try installing the latest one
Yeah you're using 2.7
yes
python --ver
so what it wont work?
python 2.7 had different syntax for print, install the latest python and try again
download python 3
let me see because i think it is not supported with my mac i have 10.13
and use it
plus my pycharm latest version was incompatible as well, i had to download an older one
macs automatically come with pre-installed python 2.*, read up on how to set up new python on mac and follow the guide
ideally in a new environment
Strange, I thought Pycharm came with an interpreter too
Or maybe thats thonny
alright, let me update and see what i can do, i'll let you guys know. thanks for the quick help
just looked it up, in 2.7 input() evaluates what the user types as python code
there's raw_input() instead
but really 2.7 is ancient at this point and I don't see a reason not to use 3 unless you're working in an old codebase or smthn
ok
just started installing 3.12
will it overwrite the 2.7
or do i have to manually delete it
and do i need to reinstall pycharm?
or will a restart suffice
don't delete the 2.7 on mac, are you following any up-to-date guides?
guides regarding?
installing python on mac
You can just click on the 2.7 at the bottomright and switch your version being used
no i just download it from their website
ok got it
theres no 3.12
i see add interpreter
Could you send a screenshot
Yeah click on "Add Interpreter..."
then?
There's probably an option to browse interpreters there
would you mind if i dm you and i share my screen?
Fine, but do note thats usually not whats encouraged here
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.