Random number lottery

This is the place for queries that don't fit in any of the other categories.

Random number lottery

Postby AdamLandau » Wed Nov 20, 2013 12:28 am

So how would I get 6 random numbers to display each time in the form of a lottery?

Easy explanations as I am new.

Numbers have to be >40
PC Specs:

i5 4670K @ 4.1Ghz
8GB Corsair Vengance RAM
Gigabyte Z87-HD3
1TB S-ATAIII 6.0Gb/s
NVIDIA GeForce GTX 760 2GB
Zalman Z11 Case
Corsair 550W PSU
AdamLandau
 
Posts: 8
Joined: Sat Nov 16, 2013 12:48 pm

Re: Random number lottery

Postby metulburr » Wed Nov 20, 2013 12:32 am

try reading:
http://docs.python.org/2/library/random.html

Code: Select all
random.randint(0,39)
New Users, Read This
OS Ubuntu 14.04, Arch Linux, Gentoo, Windows 7/8
https://github.com/metulburr
steam
User avatar
metulburr
 
Posts: 1470
Joined: Thu Feb 07, 2013 4:47 pm
Location: Elmira, NY

Re: Random number lottery

Postby micseydel » Wed Nov 20, 2013 12:33 am

Have you tried this? Perhaps after doing so, you'll be able to ask more specific questions.
Join the #python-forum IRC channel on irc.freenode.net!

Please do not PM members regarding questions which are meant to be discussed publicly. The point of the forum is so that others can benefit from it. We don't want to help you over PMs or emails.
User avatar
micseydel
 
Posts: 1367
Joined: Tue Feb 12, 2013 2:18 am
Location: Mountain View, CA


Return to General Coding Help

Who is online

Users browsing this forum: dirkaulo and 4 guests