This is a part of a bigger code. I am little confused that if I use any other digit in the below format it results in wrong values.
so instead of
fmt.Println(time.Now().Format("2006-01-02 15:04:05-07:00"))
if I try to use
fmt.Println(time.Now().Format("2006-01-02 12:04:05-04:00"))
Result is wrong. Even when it is same format, just digit change
package main
import (
"fmt"
"time"
)
func main() {
fmt.Println(time.Now().Format("2006-01-02 15:04:05-07:00"))
}
So my question is why is it so. Digits inside format have no meaning. They are just for representation of the format.