delorie.com/archives/browse.cgi | search |
Message-ID: | <3AA132DE.E46D023C@acm.org> |
From: | Eric Sosman <esosman AT acm DOT org> |
X-Mailer: | Mozilla 4.72 [en] (Win95; U) |
X-Accept-Language: | en |
MIME-Version: | 1.0 |
Newsgroups: | comp.os.msdos.djgpp |
Subject: | Re: trig function?? loopings |
References: | <Fqeo6.142$nj5 DOT 49880 AT sapphire DOT mtt DOT net> |
Lines: | 17 |
Date: | Sat, 03 Mar 2001 23:05:23 GMT |
NNTP-Posting-Host: | 12.78.198.101 |
X-Complaints-To: | abuse AT worldnet DOT att DOT net |
X-Trace: | bgtnsc05-news.ops.worldnet.att.net 983660723 12.78.198.101 (Sat, 03 Mar 2001 23:05:23 GMT) |
NNTP-Posting-Date: | Sat, 03 Mar 2001 23:05:23 GMT |
Organization: | AT&T Worldnet |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
Reply-To: | djgpp AT delorie DOT com |
Stewart wrote: > > I am trying to write a program that prompts the user for a value in degrees > and outputs the sine, cosine and tangent of the value entered. This is what > I did: > [...] > cosine = cos(degrees*180/M_PI); > [...] I don't know C++ and thus can't answer your primary question. However, I *do* know a little bit of trigonometry, and can advise you that the above line will give you the wrong answer for most values of `degrees' ... -- Eric Sosman esosman AT acm DOT org
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |