I have a simple function that simply prints "Hi!". I want to use bash to call my function, instead of lets say IDLE. However bash doesn't seem to want to print the output returned from the hi(): function.
#!/usr/bin/python
def hi():
print 'Hi!'
This doesn't print "Hi!", when I type python hi.py (or ./hi.py) into bash
However if I do not include the print statement inside of a function, but just inside the file hi.py as a lone print 'Hi!' statement; then bash does output text "Hi!" accordingly. From bash this code below outputs Hi!
#!/usr/bin/python
print 'Hi!'
From within bash, how might I make bash output the string from the function hi(): in the file hi.py?
Thanks