From: parikh@ll.mit.edu (Salil Parikh)
Subject: nint() and nintf()
Date: Mon, 27 Jun 94 02:11:05 GMT [thread overview]
Message-ID: <1994Jun27.021105.6007@ll.mit.edu> (raw)
Is it just me, or are other people having difficulties with
nint() and nintf() ?
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
void main (argc, argv)
int argc;
char *argv[];
{
double num;
num = atof(argv[1]);
printf("nint(%f) = %f\n", num, nint(num));
printf("nintf(%f) = %f\n", num, (float) nintf((float) num));
}
--output--
nint(5.700000) = 4503599627370496.000000
nintf(5.700000) = 41.000000
Thanks,
Salil
next reply other threads:[~1994-06-27 2:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1994-06-27 2:11 Salil Parikh [this message]
1994-06-27 11:53 ` nint() and nintf() John Hascall
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox