Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #98439
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: time module |
| Date | 2015-11-08 13:05 +0200 |
| Organization | A noiseless patient Spider |
| Message-ID | <87vb9cwy3l.fsf@elektro.pacujo.net> (permalink) |
| References | <mailman.114.1446941944.16136.python-list@python.org> <sqF%x.23626$mP1.4332@fx24.ams1> |
input/ldompeling@casema.nl:
> Yes, I would like seconds since start of program.
> Can I not doing something like time()=0 only this gives an error.
Here:
class MyReckoning:
def __init__(self):
self.the_beginning = time.time()
def time(self):
return time.time() - self.the_beginning
reckoning = MyReckoning()
print(reckoning.time())
Marko
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread
time module input/ldompeling@casema.nl - 2015-11-07 21:27 +0000
Re: time module Cameron Simpson <cs@zip.com.au> - 2015-11-08 08:47 +1100
Re: time module Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2015-11-07 19:19 -0500
Re: time module input/ldompeling@casema.nl - 2015-11-08 10:25 +0000
Re: time module Marko Rauhamaa <marko@pacujo.net> - 2015-11-08 13:05 +0200
csiph-web