setTimeout and setInterval together -- repeating a pause
<p>In javascript, I need to do the following, written in pseudocode:</p>

<pre><code>REPEAT EVERY 5 SECONDS
    print 'One'
    wait 2.5 seconds
    print 'Two'
    wait 2.5 seconds
</code></pre>

<p>How can I do this? My (clumsy?) attempt follows:</p>

<pre><code>a = setInterval(function() { 
     setTimeout(function(){print 'one'},0);
     setTimeout(function(){print 'two'},2500);
    },5000);
</code></pre>

<p>Improvements?</p>
