Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #98439
| Path | csiph.com!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail |
|---|---|
| From | Marko Rauhamaa <marko@pacujo.net> |
| Newsgroups | comp.lang.python |
| Subject | Re: time module |
| Date | Sun, 08 Nov 2015 13:05:02 +0200 |
| Organization | A noiseless patient Spider |
| Lines | 19 |
| Message-ID | <87vb9cwy3l.fsf@elektro.pacujo.net> (permalink) |
| References | <mailman.114.1446941944.16136.python-list@python.org> <sqF%x.23626$mP1.4332@fx24.ams1> |
| Mime-Version | 1.0 |
| Content-Type | text/plain |
| Injection-Info | mx02.eternal-september.org; posting-host="b7cb1518d23ec19d482dcc9c31d30fdd"; logging-data="7671"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+WD9w90RGCtCN+l0sgv0PR" |
| User-Agent | Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
| Cancel-Lock | sha1:QguPJPIG/Dq2FH4B4rL4/Y0DU9o= sha1:LCyN2OJkocS/wrF4Fxezj8n+NJQ= |
| Xref | csiph.com comp.lang.python:98439 |
Show key headers only | View raw
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