SORU
22 EKİM 2010, Cuma


0 ve 9 arasında rastgele bir tamsayı üretir

Nasıl rastgele oluşturabilirsiniztamsayılarnumaraları0<9(uç dahil) python?

yani 0 1 2 3 4 5 6 7 8 9

CEVAP
22 EKİM 2010, Cuma


Deneyin:

from random import randint
print(randint(0,9))

Daha fazla bilgi: https://docs.python.org/3.1/library/random.html#random.randint

Bunu Paylaş:
  • Google+
  • E-Posta
Etiketler:

YORUMLAR

SPONSOR VİDEO

Rastgele Yazarlar

  • ★TheCrono Official Channel★

    ★TheCrono

    3 Mayıs 2014
  • RD

    RD

    19 NİSAN 2006
  • WHZGUD2

    WHZGUD2

    21 EYLÜL 2011