"%T" what does it mean?

I can’t remember what this means, and I don’t know where to find the answer

a Go-syntax representation of the type of the value

From the fmt documentation.

At least in a format string this is true, in other contexts it may have other meanings, but possibly, most of the time it’s just a string with a percent symbol and a capital T.

Thanks for the definition. So when I type “%T” in a program, what it does is to type that value?

Run this to see how it works:
https://play.golang.org/p/GAyy_87sjsi

1 Like

Cool! That really helped! Why do I get so excited? Sincerely better than a football game on the radio :grinning:

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.