Hans Nowak schrieb:

In this case, you can just use a slice, as localtime is a tuple:

    fmttime = "%04d-%02d-%02d %02d:%02d:%02d" % localtime[:6]

Hope this helps! ^_^

Ahh, how cool! That's *exactly* what I meant with "awesome Python magic" :-)

Amazing language, I have to admit.

Regards,
Johannes

--
"Wer etwas kritisiert muss es noch lange nicht selber besser können. Es
reicht zu wissen, daß andere es besser können und andere es auch
besser machen um einen Vergleich zu bringen."     -     Wolfgang Gerber
      in de.sci.electronics <[EMAIL PROTECTED]>
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to