random

package
v0.2.26 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 16, 2024 License: MIT Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init()

Init must be called at the start of every program.

If CODECRAFTERS_RANDOM_SEED is set, it will be used to generate predictable random numbers.

func RandomInt added in v0.2.2

func RandomInt(min, max int) int

RandomInt returns a random integer between min and max.

func RandomString

func RandomString() string

RandomString returns a random string of 6 words.

func RandomStrings

func RandomStrings(n int) []string

RandomStrings returns a random list of n strings.

func RandomWord

func RandomWord() string

RandomWord returns a random word from the list of words.

func RandomWords

func RandomWords(n int) []string

RandomWords returns a random list of n words.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL