chore(go): add comments [skip ci]
This commit is contained in:
parent
3f77c573a6
commit
21b4888277
@ -246,6 +246,7 @@ func HillClimb(
|
|||||||
funcStats.BenchResults = make([]stats.BenchRound, minIters)
|
funcStats.BenchResults = make([]stats.BenchRound, minIters)
|
||||||
|
|
||||||
// create and seed a source of preudo-randomness
|
// create and seed a source of preudo-randomness
|
||||||
|
// rand.Seed(uint64(time.Now().UnixNano()))
|
||||||
src := rand.NewSource(uint64(rand.Int63()))
|
src := rand.NewSource(uint64(rand.Int63()))
|
||||||
// src := rand.NewSource(uint64(time.Now().UnixNano()))
|
// src := rand.NewSource(uint64(time.Now().UnixNano()))
|
||||||
|
|
||||||
@ -291,7 +292,7 @@ func HillClimb(
|
|||||||
bestVals,
|
bestVals,
|
||||||
)
|
)
|
||||||
|
|
||||||
// first or any other iteration.
|
// first or any of the subsequent iterations.
|
||||||
switch i {
|
switch i {
|
||||||
case 0:
|
case 0:
|
||||||
bestResult = r
|
bestResult = r
|
||||||
|
Loading…
Reference in New Issue
Block a user