How to Skip Numbers In Each Iteration Loop String in Python?
<p>I'm very new to this: but I have this string:</p>

<pre><code>urls = ['http://example.com/page_%s.html' % page for page in xrange(0,50)]
</code></pre>

<p>which runs from 0,1,2,3 ... 50. </p>

<p>The question is how can i make run by skipping 5 number in each iteration? </p>

<p>The number should run like this: 0, 5, 10, 15 ... 50.</p>

<p>You can try this:</p>

<pre><code>urls = map('http://example.com/page_{}.html'.format, range(0, 50, 5))
</code></pre>

<p><code>range</code> and <code>xrange</code> take an optional <code>step</code> argument as the third parameter.</p>

python