Re: How do I call the double() function?

2009-03-21 Thread John Machin
On Mar 22, 2:21 am, grocery_stocker wrote: > On Mar 21, 8:11 am, John Machin wrote: > > > > > On Mar 22, 1:55 am, grocery_stocker wrote: > > > > Given the following > > > > def double(val): > > >     return val.bind(lambda x: val.return_(x*2)) > > > > I get "AttributeError: 'int' object has

Re: How do I call the double() function?

2009-03-21 Thread grocery_stocker
On Mar 21, 8:21 am, Kushal Kumaran wrote: > On Mar 21, 7:55 pm, grocery_stocker wrote: > > > Given the following > > > def double(val): > > return val.bind(lambda x: val.return_(x*2)) > > > I get "AttributeError: 'int' object has no attribute 'bind' " when I > > try to do the following >

Re: How do I call the double() function?

2009-03-21 Thread Kushal Kumaran
On Mar 21, 7:55 pm, grocery_stocker wrote: > Given the following > > def double(val): >     return val.bind(lambda x: val.return_(x*2)) > > I get "AttributeError: 'int' object has no attribute 'bind' " when I > try to do the following > > double(2) > > See the usage of the double function in

Re: How do I call the double() function?

2009-03-21 Thread grocery_stocker
On Mar 21, 8:11 am, John Machin wrote: > On Mar 22, 1:55 am, grocery_stocker wrote: > > > > > Given the following > > > def double(val): > > return val.bind(lambda x: val.return_(x*2)) > > > I get "AttributeError: 'int' object has no attribute 'bind' " when I > > try to do the following >

Re: How do I call the double() function?

2009-03-21 Thread John Machin
On Mar 22, 1:55 am, grocery_stocker wrote: > Given the following > > def double(val): >     return val.bind(lambda x: val.return_(x*2)) > > I get "AttributeError: 'int' object has no attribute 'bind' " when I > try to do the following > > double(2) > > Below is the output... > > [cdal...@local

How do I call the double() function?

2009-03-21 Thread grocery_stocker
Given the following def double(val): return val.bind(lambda x: val.return_(x*2)) I get "AttributeError: 'int' object has no attribute 'bind' " when I try to do the following double(2) Below is the output... [cdal...@localhost ~]$ python Python 2.4.3 (#1, Oct 1 2006, 18:00:19) [GCC 4.