Changes to avoid fmt.Printf in console,this would not be recommended for usage instead we can use logger.And also to return float64 value for duration rather than int because in case of having duration as int will return original value 3.99 sec as 3 sec which is not valid
Changes to avoid fmt.Printf in console,this would not be recommended for usage instead we can use logger.And also to return float64 value for duration rather than int because in case of having duration as int will return original value 3.99 sec as 3 sec which is not valid