Refactor random functions
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
package random
|
||||
|
||||
import (
|
||||
"crypto/rand"
|
||||
"math/big"
|
||||
)
|
||||
|
||||
func Int64(max int64) int64 {
|
||||
rnd, _ := rand.Int(rand.Reader, big.NewInt(max))
|
||||
return rnd.Int64()
|
||||
}
|
||||
Reference in New Issue
Block a user