calling function in X seconds
<p>In a function, I want to call one line in every 2 seconds. Whenever I use sleep function, the code wait 2 seconds then going to the next instruction. But, I want to call a function in every 2 seconds without disturbing other instructions. Example;</p>

<pre><code>a = None
def foo():
    bar()

    a = a * 12 
    print "A : ",a

def bar():
    a = 0
</code></pre>

<p>Every two seconds, a should be resetted. But, in two seconds value of a should be incremented and displayed. Is it possible ? How ?</p>
