Calling J from Python

Bruno Desthuilliers bdesth.quelquechose at free.quelquepart.fr
Mon Feb 5 15:22:07 EST 2007


Larry Bates a écrit :
> 
> def avg(l):
>     return float(sum(l))/len(l)
> 
> 
>>>>avg([1,2,3,4])
> 
> 2.5

def avg(*args):
   return float(sum(args)) / len(args))

> 
> Which can actually be read and debugged in the future!

in_my_arms(tm)



More information about the Python-list mailing list