How to set the Zone of a Go time value when knowing the UTC time and time offset?

Viewed 3794

I have an UTC time and a time offset in seconds, and need to return the corresponding Go time value.

It is trivial to instantiate the UTC time value by using the time.Unix() function. But to set the Zone, I need to determine the time.Location.

How can I find the time.Location when knowing the UTC time and time offset ?

1 Answers
Related