Is there a difference between Python shell and PyCharm in codeing?

0 Refs Nart · May 24, 2015
Hi guys
def approp (my_age):
    girls_age = my_age / 2 + 7
    return girls_age
whenever I enter approp() it respond with girls_age immediately, is that ok? cause in the tutorial typing that will produce nothing.
I'm using Python 3.4.3, no PyCharm

Post a Reply

Replies

Oldest  Newest  Rating
0 Pavel Dimi · May 27, 2015
The python shell is used to try small code snippets and play around with something. It is ok if you call a function to get the returned value printed, the same thing goes for a variable and etc. Keep in mind that if a function returns None it will not be printed. The shell by default does not print None value, if you type None and press enter you wll just be on a new line, unlike for example string which will be printed on the next line.
0 Halcyon Abraham Ramirez · May 30, 2015
when you type approp() you are calling your approp function that's why it shows girls_age.

try using IDLE

if you are on windows hit the windows button and search for IDLE and you should see IDLE python GUI or something
  • 1

Python

107,237 followers
About

This section is all about snakes! Just kidding.

Links
Moderators
Bucky Roberts Administrator