Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

README: fix rand.Seed usage in examples #27

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

dolmen
Copy link

@dolmen dolmen commented Apr 5, 2018

  • Move rand.Seed out of lambdas
  • use time.Now().UnixNano() instead of time.Now().UTC().UnixNano() as seed

dolmen added 2 commits April 5, 2018 16:14
Seed just once (not on every call to rand) by moving call to rand.Seed
out of lambdas.
Use time.Now().UnixNano() instead of time.Now().UTC().UnixNano() because
using UTC brings nothing to seed a random number generator
@dolmen dolmen requested a review from aymerick February 11, 2020 11:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant