Thanks !

On Jun 30, 5:31 pm, "Mike Hansen" <[EMAIL PROTECTED]> wrote:
> Hello,
>
> In Python you can use *args and **kwds in the function definition to
> match optional arguments and keyword arguments; args will be a tuple
> of the arguments and kwds will be a dictionary for the keyword
> arguments.  For example, look at the behavior of the following
> function:
>
> sage: def f(*args, **kwds): print args, kwds
> sage: f(1,2,3)
> (1, 2, 3) {}
> sage: f(1,2,3,optional=True)
> (1, 2, 3) {'optional': True}
> sage: f(optional=True)
> () {'optional': True}
> sage: f(4, 5, optional=True, cat="dog")
> (4, 5) {'optional': True, 'cat': 'dog'}
>
> --Mike
>
> On Mon, Jun 30, 2008 at 9:14 AM, ibrahim <[EMAIL PROTECTED]> wrote:
>
> > Hello !
>
> > How to do so if possible ?
> > Thanks.
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to