Datetime question

Rama ramasubramani.g at gmail.com
Thu Aug 3 10:38:04 EDT 2006


Ah, true. Sorry. I got thrown by the ouput after the line got executed and
assumed it was the value of a.

thanks,
Rama



On 03/08/06, Simon Brunning <simon at brunningonline.net> wrote:
>
> On 8/3/06, Rama <ramasubramani.g at gmail.com> wrote:
> > Just curious why when
> > I call id(a) I get the same id after I call the replace method.
>
> In your example, you called a's replace() method, but did nothing with
> the new datetime object that it returned. The original object, a,
> naturally still has the same ID, but it also still has the same value.
>
> --
> Cheers,
> Simon B,
> simon at brunningonline.net,
> http://www.brunningonline.net/simon/blog/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20060803/59eed129/attachment.html>


More information about the Python-list mailing list