What is the difference between the time package’s Time.Sub() and Time.Add() methods?
time
Time.Sub()
Time.Add()
Time.Add() accepts a Duration parameter and returns a Time while Time.Sub() accepts a Time parameter and returns a Duration.
Time.Add() is for performing addition while Time.Sub() is for nesting timestamps.
Time.Add() always returns a later time while time.Sub always returns an earlier time.
They are opposites. Time.Add(x) is the equivalent of Time.Sub(-x).