Java,BigInteger
Fermé
samdevlop
Messages postés
142
Date d'inscription
lundi 10 septembre 2007
Statut
Membre
Dernière intervention
27 mai 2010
-
13 mai 2009 à 21:25
Utilisateur anonyme - 14 mai 2009 à 18:30
Utilisateur anonyme - 14 mai 2009 à 18:30
A voir également:
- Biginteger java
- Waptrick java football - Télécharger - Jeux vidéo
- Java apk - Télécharger - Langages
- Jeux java itel football - Télécharger - Jeux vidéo
- Jeux java itel 5360 ✓ - Forum Mobile
- Java jre - Télécharger - Langages
2 réponses
Utilisateur anonyme
14 mai 2009 à 03:44
14 mai 2009 à 03:44
Salut,
Il y a ceci dans la doc...
https://docs.oracle.com/javase/6/docs/api/
Mais peut_être l'as tu déjà vu?
BigInteger
public BigInteger(int numBits,
Random rnd)
Constructs a randomly generated BigInteger, uniformly distributed over the range 0 to (2numBits - 1), inclusive. The uniformity of the distribution assumes that a fair source of random bits is provided in rnd. Note that this constructor always constructs a non-negative BigInteger.
Parameters:
numBits - maximum bitLength of the new BigInteger.
rnd - source of randomness to be used in computing the new BigInteger.
Throws:
IllegalArgumentException - numBits is negative.
See Also:
bitLength()
--------------------------------------------------------------------------------
BigInteger
public BigInteger(int bitLength,
int certainty,
Random rnd)
Constructs a randomly generated positive BigInteger that is probably prime, with the specified bitLength.
It is recommended that the probablePrime method be used in preference to this constructor unless there is a compelling need to specify a certainty.
Parameters:
bitLength - bitLength of the returned BigInteger.
certainty - a measure of the uncertainty that the caller is willing to tolerate. The probability that the new BigInteger represents a prime number will exceed (1 - 1/2certainty). The execution time of this constructor is proportional to the value of this parameter.
rnd - source of random bits used to select candidates to be tested for primality.
Throws:
ArithmeticException - bitLength < 2.
See Also:
bitLength()
Cordialement,
Dan
Il y a ceci dans la doc...
https://docs.oracle.com/javase/6/docs/api/
Mais peut_être l'as tu déjà vu?
BigInteger
public BigInteger(int numBits,
Random rnd)
Constructs a randomly generated BigInteger, uniformly distributed over the range 0 to (2numBits - 1), inclusive. The uniformity of the distribution assumes that a fair source of random bits is provided in rnd. Note that this constructor always constructs a non-negative BigInteger.
Parameters:
numBits - maximum bitLength of the new BigInteger.
rnd - source of randomness to be used in computing the new BigInteger.
Throws:
IllegalArgumentException - numBits is negative.
See Also:
bitLength()
--------------------------------------------------------------------------------
BigInteger
public BigInteger(int bitLength,
int certainty,
Random rnd)
Constructs a randomly generated positive BigInteger that is probably prime, with the specified bitLength.
It is recommended that the probablePrime method be used in preference to this constructor unless there is a compelling need to specify a certainty.
Parameters:
bitLength - bitLength of the returned BigInteger.
certainty - a measure of the uncertainty that the caller is willing to tolerate. The probability that the new BigInteger represents a prime number will exceed (1 - 1/2certainty). The execution time of this constructor is proportional to the value of this parameter.
rnd - source of random bits used to select candidates to be tested for primality.
Throws:
ArithmeticException - bitLength < 2.
See Also:
bitLength()
Cordialement,
Dan
Utilisateur anonyme
14 mai 2009 à 18:30
14 mai 2009 à 18:30
Salut,
Tu cliques sur ce lien (qui n'est pas un tuto, mais la doc Sun Java Platform SE 6)
Ensuite dans la fenêtre All Classes tu recherches la classe BigInteger que tu cliques.
En faisant défiler cette nouvelle fenêtre (class BigInteger) jusqu'à trouver Constructor Detail, tu obtiens tous les cas dont :
public BigInteger(int numBits,
Random rnd)
Cordialement,
Dan
Tu cliques sur ce lien (qui n'est pas un tuto, mais la doc Sun Java Platform SE 6)
Ensuite dans la fenêtre All Classes tu recherches la classe BigInteger que tu cliques.
En faisant défiler cette nouvelle fenêtre (class BigInteger) jusqu'à trouver Constructor Detail, tu obtiens tous les cas dont :
public BigInteger(int numBits,
Random rnd)
Cordialement,
Dan
14 mai 2009 à 17:01