Skip to content

Instantly share code, notes, and snippets.

@tqbf
Created September 25, 2012 01:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tqbf/3779471 to your computer and use it in GitHub Desktop.
Save tqbf/3779471 to your computer and use it in GitHub Desktop.
// Increment counter
for i := len(x.ctr) - 1; i >= 0; i-- {
x.ctr[i]++
if x.ctr[i] != 0 {
break
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment