summaryrefslogtreecommitdiff
path: root/ratio.c
diff options
context:
space:
mode:
authorJulian Weigt <juw@posteo.de>2026-01-15 22:31:04 +0100
committerJulian Weigt <juw@posteo.de>2026-02-04 15:55:52 +0100
commit96916ac21687177bdf519d51919feeda5376b09f (patch)
treeed8f2517adba7779a2a69e9a4284c5163d0b8fdc /ratio.c
parent10802b807e001bce40c2d668a7ff7caa072340f7 (diff)
Add "…" to string conversion output.
Diffstat (limited to 'ratio.c')
-rw-r--r--ratio.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ratio.c b/ratio.c
index 747aeab..3bb5ef3 100644
--- a/ratio.c
+++ b/ratio.c
@@ -137,12 +137,12 @@ double to_double(rational r){
bool to_string(char* s, rational r){
double f = to_double(r);
- sprintf(s,"%llu / %llu = %f +/- %6.1e",r.n,r.d,f,f*DBL_EPSILON);
+ sprintf(s,"%llu / %llu = %f… +/- %6.1e",r.n,r.d,f,f*DBL_EPSILON);
return true;
}
bool root_to_string(char* s, rational r, unsigned int p){
double f = pow(to_double(r),1.0/p);
- sprintf(s,"(%llu / %llu)^1/%i = %f +/- %6.1e",r.n,r.d,p,f,2*DBL_EPSILON*f);
+ sprintf(s,"(%llu / %llu)^1/%i = %f… +/- %6.1e",r.n,r.d,p,f,2*DBL_EPSILON*f);
return true;
}