关于作者

Discuss / Python / 有一点小问题

有一点小问题

问题来源

JOIEUH

#1 Created at ...

def now(): print('abc')

f = now() #运行会出现abc

f = abs(-10) #运行却没有出现结果

这是为什么?,按道理来说f = now()不应该出现结果,因为这个不是相当于赋值吗,结果不会显示出来才对?

廖雪峰

#2 Created at ...

注意区分 f = now() 和 f = now


  • 1

Reply

WARNING: You are using an old browser that does not support HTML5. Please choose a modern browser (Chrome / Microsoft Edge / Firefox / Sarafi) to get a good experience.