Sublime Forum

How to work def module?

#1

Hello. I am so excited to be here.
I am learning to completely beginner of codeacademy .Very simple thing was not working. I read some of the shortcut manner, but I do not understand well, about for result in creating a new function called hello.
Example: def hello():
print “Hello”
print “Computers are Fun”

How can i get to this work.
I see [Finished in 0.1s] ,

0 Likes

#2

It should be covered in your course, but the code you have written defines a function but doesn’t call it. You probably want something like:

def hello(): 
    print "Hello"
    print "Computers are Fun"

hello()
0 Likes