Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
package main
import (
func main(){
var num uint8 = 5
var paddedString string = fmt.Sprintf("%02d", num)
log.Println(paddedString) // 05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment