On Wednesday, November 30, 2016 at 8:11:49 PM UTC+5:30, vnthma...@gmail.com
wrote:
> from threading import Timer
>
> class TestTimer:
> def foo(self):
> print("hello world")
> self.startTimer()
>
> def startTimer(self):
> self.t1 = Timer(5, self.foo)
> sel
On Wednesday, November 30, 2016 at 7:35:46 PM UTC+5:30, siva gnanam wrote:
> The following program print hello world only once instead it has to print the
> string for every 5 seconds.
>
> from threading import Timer;
>
> class TestTimer:
>
>
The following program print hello world only once instead it has to print the
string for every 5 seconds.
from threading import Timer;
class TestTimer:
def __init__(self):
self.t1 = Timer(5.0, self.foo);
def startTimer(self):
self.t1.start();