code: func (b *backoff) Duration() (dur time.Duration) {
  	// Zero-values are nonsensical, so we use
  	// them to apply defaults
  	if b.Max == 0 {
  		b.Max = 10 * time.Second
  	}
  
  	if b.Initial == 0 {
  		b.Initial = 100 * time.Millisecond
  	}
  
  	// calculate this duration
  	if dur = time.Duration(1 << uint(b.attempts)); dur > 0 {
  		dur = dur * b.Initial
  	} else {
  		dur = b.Max
  	}
  
  	if b.Jitter > 0 {
  		dur = dur + time.Duration(rand.Intn(int(b.Jitter)))
  	}
  
  	// bump attempts count
  	b.attempts++
  
  	return dur
  }
docs: // Returns the current value of the counter and then multiplies it
  // Factor