如何将多个字符串传递到http get中的url中?

This is my current code:

var dek string = "dk"
resp,err := c.Get("https://google."VALUEHERE"")

What I want to be able to is pass different strings into my url if I need a bunch of different ones.

So ideally would be something like:

resp,err := c.Get("https://google.dk/value1=%v&value2=%v", value1, value2)

Is this possible in any way?

Use fmt.Sprintf(...) to build a string that does not require encoding:

hostname := fmt.Sprintf("google.%s", "dk")
// => "google.dk"

Use the net/url package to build URLs so they are encoded properly:

u := &url.URL{Scheme: "https", Host: hostname}
fmt.Println(u)
// => https://google.dk

q := u.Query()
q.Add("value1", "foo")
q.Add("value2", "Hello, World!")
u.RawQuery = q.Encode()
fmt.Println(u)
// => https://google.dk?value1=foo&value2=Hello%2C+World%21

resp, err := c.Get(u.String())
// ...