Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #101270
| Newsgroups | comp.lang.python |
|---|---|
| Date | 2016-01-05 05:04 -0800 |
| References | <6b0e236f-b240-486d-95e6-17bba9458cde@googlegroups.com> <mailman.10.1451960795.2305.python-list@python.org> <ca45fc5d-60ce-4df2-a441-0e85a4b05003@googlegroups.com> <mailman.11.1451964493.2305.python-list@python.org> |
| Message-ID | <aeb127ae-f1a4-4cc6-965b-693cdd50036e@googlegroups.com> (permalink) |
| Subject | Re: Is '*args' useful in this example code? |
| From | Robert <rxjwg98@gmail.com> |
On Monday, January 4, 2016 at 10:28:31 PM UTC-5, Ben Finney wrote: > Robert <.com> writes: > > > On Monday, January 4, 2016 at 9:26:47 PM UTC-5, Ben Finney wrote: > > > Can you show example code that you would expect, and specifically what about > > > the actual code doesn't match what you expect? > > > > Excuse me for the incomplete info previously. > > If I call it with > > a = f(3) > > the result is 12. > > Can you show a *very* simple example of the 'f' you're talking about? > Contrive a new one, make it behave the same way while keeping it very > short, and once you have that, put that code in your message. > > With an actual function to examine it will be much easier to know where > the confusion lies. > > -- > \ "When a well-packaged web of lies has been sold to the masses | > `\ over generations, the truth will seem utterly preposterous and | > _o__) its speaker a raving lunatic." --Dresden James | > Ben Finney Excuse me, Ben. I forgot to add the f function. It is as below: @logged def f(x): """does some math""" return x + x * x a = f(3) My problem has been solved after all of your helpful posts. Thanks.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Is '*args' useful in this example code? Robert <rxjwg98@gmail.com> - 2016-01-04 18:16 -0800
Re: Is '*args' useful in this example code? Ben Finney <ben+python@benfinney.id.au> - 2016-01-05 13:26 +1100
Re: Is '*args' useful in this example code? Robert <rxjwg98@gmail.com> - 2016-01-04 18:34 -0800
Re: Is '*args' useful in this example code? Ben Finney <ben+python@benfinney.id.au> - 2016-01-05 14:28 +1100
Re: Is '*args' useful in this example code? Robert <rxjwg98@gmail.com> - 2016-01-05 05:04 -0800
Re: Is '*args' useful in this example code? Arif Khokar <akhokar1234@wvu.edu> - 2016-01-04 22:29 -0500
Re: Is '*args' useful in this example code? Antoon Pardon <antoon.pardon@rece.vub.ac.be> - 2016-01-05 12:51 +0100
csiph-web