From: "Jason Yip" Newsgroups: comp.os.msdos.djgpp Subject: Why the value of "c" is always "-17.78"?? Date: Sun, 5 Dec 1999 13:33:52 +0800 Organization: netteens.net (Hongkong Telecom IMS) Lines: 27 Message-ID: <82ctj1$i7b$1@imsp026.netvigator.com> NNTP-Posting-Host: olkc10216.netvigator.com X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2615.200 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Can anyone tells me why the value of "c" is always -17.78?? Thank a lot!! #include float ftc(n) int n; { float c, f; int i; for (i=0;i<=n;i++){ c=5.0/9.0*(f-32); } return c; } main () { float c, f=0; int i=0; do { c=ftc(i); printf("\t\t F=%.2f \t\t C=%.2f\n",f,c); f++; i++; } while (i<=100); }