예제 #1
0
# main.py
import words
# 不用加副檔名
print(words.GREETING)
print(words.THANKS)
print(words.MYNAME)
print(words.MYPRO)

# main.py
import opening
import ending

opening.say()
ending.say()
예제 #2
0
import opening
import ending

opening.say()  #雖然都是say function,但是是在不同的module底下,即不同scope,所以不會互相干擾。
ending.say()