difference between random module in python 2.6 and 3.2?

Aaron France a.france.mailinglists at gmail.com
Mon Feb 6 13:48:40 EST 2012


On 02/06/2012 09:57 AM, Matej Cepl wrote:
> On 6.2.2012 09:45, Matej Cepl wrote:
>> Also, how could I write a re-implementation of random.choice which would
>> work same on python 2.6 and python 3.2? It is not only matter of unit
>> tests, but I would really welcome if the results on both versions
>> produce the same results.
>
> Silly, of course, the solution is obvious ... I have just embedded 
> random.choice from 2.6 to my code.
>
> Matěj
Is the above actually a good idea though?

What I understand you're doing is embedding the source from the 
Python2.6 random.py file, /into/ your project files?

Regards,
A


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20120206/b09ab1c9/attachment-0001.html>


More information about the Python-list mailing list