Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 13 of 13 for Int63n (0.13 sec)

  1. cmd/test-utils_test.go

    var src = rand.NewSource(time.Now().UnixNano())
    
    func randString(n int) string {
    	b := make([]byte, n)
    	// A src.Int63() generates 63 random bits, enough for letterIdxMax characters!
    	for i, cache, remain := n-1, src.Int63(), letterIdxMax; i >= 0; {
    		if remain == 0 {
    			cache, remain = src.Int63(), letterIdxMax
    		}
    		if idx := int(cache & letterIdxMask); idx < len(letterBytes) {
    			b[i] = letterBytes[idx]
    			i--
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Oct 01 22:13:18 UTC 2024
    - 77K bytes
    - Viewed (0)
  2. cmd/object-api-utils.go

    	// 4 MB block.
    	// Approx runtime ~30ms
    	data := make([]byte, 4<<20)
    	rng := rand.New(rand.NewSource(0))
    	for i := range data {
    		// Generate compressible stream...
    		data[i] = byte(rng.Int63() & 3)
    	}
    	failOnErr := func(err error) {
    		if err != nil {
    			logger.Fatal(errSelfTestFailure, "compress: error on self-test: %v", err)
    		}
    	}
    	const skip = 2<<20 + 511
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Aug 08 15:29:58 UTC 2024
    - 37.1K bytes
    - Viewed (0)
  3. api/go1.txt

    pkg math/rand, func Float32() float32
    pkg math/rand, func Float64() float64
    pkg math/rand, func Int() int
    pkg math/rand, func Int31() int32
    pkg math/rand, func Int31n(int32) int32
    pkg math/rand, func Int63() int64
    pkg math/rand, func Int63n(int64) int64
    pkg math/rand, func Intn(int) int
    pkg math/rand, func New(Source) *Rand
    pkg math/rand, func NewSource(int64) Source
    pkg math/rand, func NewZipf(*Rand, float64, float64, uint64) *Zipf
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Wed Aug 14 18:58:28 UTC 2013
    - 1.7M bytes
    - Viewed (0)
Back to top