Python: Convert list of ints to one number?
<p>I have a list of integers that I would like to convert to one number like:</p>

<pre><code>numList = [1,2,3]
num = magic(numList)

print num, type(num)
&gt;&gt;&gt; 123, &lt;type 'int'&gt;
</code></pre>

<p>What is the best way to implement the <i>magic</i> function?</p>

<p>Thanks for your help.</p>

<p><b>EDIT</b> <br>
I did find <a href="http://bytes.com/groups/python/722951-int-str-list-elements">this</a>, but it seems like there has to be a better way.</p>

<p><b>EDIT 2</b> <br>
Let's give some credit to <a href="http://stackoverflow.com/questions/489999/python-convert-list-of-ints-to-one-number#490020">Triptych</a> and <a href="http://stackoverflow.com/questions/489999/python-convert-list-of-ints-to-one-number#490031">cdleary</a> for their great answers!  Thanks guys.</p>
