diff --git a/main.go b/main.go index c68af76..48ba0dd 100644 --- a/main.go +++ b/main.go @@ -58,10 +58,10 @@ func main() { res, err := compute.Evaluate(text) if err != nil { - fmt.Println("Error: " + err.Error()) + term.Write([]byte(fmt.Sprintln("Error: " + err.Error()))) continue } - fmt.Printf("%s\n", strconv.FormatFloat(res, 'G', -1, 64)) + term.Write([]byte(fmt.Sprintf("%s\n", strconv.FormatFloat(res, 'G', -1, 64)))) } }