Viewing file: Crypto.Random.random.StrongRandom-class.html (13.34 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
Crypto.Random.random.StrongRandom
Class StrongRandom
object --+
|
StrongRandom
|
__init__(self,
rng=None,
randfunc=None)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature |
|
|
|
getrandbits(self,
k)
Return a python long integer with k random bits. |
|
|
|
randrange(self,
*args)
randrange([start,] stop[, step]):
Return a randomly-selected element from range(start, stop, step). |
|
|
|
randint(self,
a,
b)
Return a random integer N such that a <= N <= b. |
|
|
|
choice(self,
seq)
Return a random element from a (non-empty) sequence. |
|
|
|
shuffle(self,
x)
Shuffle the sequence in place. |
|
|
|
sample(self,
population,
k)
Return a k-length list of unique elements chosen from the population sequence. |
|
|
Inherited from object :
__delattr__ ,
__format__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__sizeof__ ,
__str__ ,
__subclasshook__
|
Inherited from object :
__class__
|
__init__(self,
rng=None,
randfunc=None)
(Constructor)
|
|
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
- Overrides:
object.__init__
- (inherited documentation)
|
Return a random element from a (non-empty) sequence.
If the seqence is empty, raises IndexError.
|
|