package main import ( "fmt" "time" ) func main() { m, _ := time.ParseDuration("1m30s") fmt.Printf("%d microseconds.", m.Microseconds()) }