On Wed, Jun 11, 2008 at 7:54 PM, Andrew Jorgensen
<[EMAIL PROTECTED]> wrote:
> This comes up every month at PLUG (for door prizes) so I thought I'd ask 
> here.  What's an
> easy to remember way to generate a random number between 1 and some given 
> number.

Here is a two liner in the Python shell...

import random
random.randint(1,100)

The real programmers on the list will probably point out that this
isn't really random or show a way to cut 4 keystrokes out, but it
might meet the original requirements above.


JP

/*
PLUG: http://plug.org, #utah on irc.freenode.net
Unsubscribe: http://plug.org/mailman/options/plug
Don't fear the penguin.
*/

Reply via email to