CkPython
CkPython
Generating Random Integer in Range
See more PRNG Examples
Demonstrates how to generate random integers in a specified range.Chilkat CkPython Downloads
import chilkat
success = False
# This example assumes the Chilkat API to have been previously unlocked.
# See Global Unlock Sample for sample code.
success = False
fortuna = chilkat.CkPrng()
# Generate random integers between 12 and 24 inclusive
for i in range(0,101):
print(str(fortuna.RandomInt(12,24)))