1

why are the output of those codes different?

fmt.Println(Join([]string{"name=xxx", string(127)}, "&"))

output name=xxx&

fmt.Println(Join([]string{"name=xxx", "127"}, "&"))

output name=xxx&127

Any help!

1 Answer 1

5

string(127) means the character whose code is 127, it is not printable. use strconv

Not the answer you're looking for? Browse other questions tagged or ask your own question.