Format difftime in a convenient way

fmt(x)

Arguments

x

difftime

Value

formatted difftime

Examples

now = Sys.time()
after = Sys.time() + 1000
if (FALSE) fmt(after - now)
if (FALSE) fmt(now - after)