# HG changeset patch # User zaitsev.serge # Date 1440938706 0 # Node ID d966bcb229c0a90d18b4ed676c5239008e3a6848 # Parent 42b0a9fa588338f5e9594e1ba0c43744c1eee062 fixed math package diff -r 42b0a9fa5883 -r d966bcb229c0 zs_ext.go --- a/zs_ext.go Sun Aug 30 12:42:22 2015 +0000 +++ b/zs_ext.go Sun Aug 30 12:45:06 2015 +0000 @@ -7,8 +7,9 @@ "strings" "time" + "math" + "github.com/drhodes/golorem" - "github.com/google/gxui/math" "github.com/jaytaylor/html2text" ) @@ -98,5 +99,5 @@ // zs timetoread -- returns number of minutes required to read the text func TimeToRead(args []string) int { wc := WordCount(args) - return int(math.Round(float64(wc) / float64(200))) + return int(math.Floor(float64(wc)/200.0 + .5)) }