Re: I couldn't use the sign funcion inside of another function

2012-04-23 Thread Emile van Sebille
On 4/23/2012 11:39 AM Chris Rebert said... On Mon, Apr 23, 2012 at 11:29 AM, Julio Sergio wrote: I want to use the sign function. When I use it in in-line mode works pretty well: : sign(-20) : -1 However, I wrote the following code in a file, say, pp.py def tst(x): s = sign(x)

Re: I couldn't use the sign funcion inside of another function

2012-04-23 Thread Chris Rebert
On Mon, Apr 23, 2012 at 11:29 AM, Julio Sergio wrote: > I want to use the sign function. When I use it in in-line mode works pretty > well: > >   : sign(-20) >   : -1 > > However, I wrote the following code in a file, say, pp.py > > def tst(x): >    s = sign(x) >    return(s) > > Then I tried to i