Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Robert <rkfb1965@googlemail.com> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: Computed values don't tie up |
| Followup-To | comp.lang.c |
| Date | 2012-04-03 21:38 +0000 |
| Message-ID | <9u15esF7g3U2@mid.individual.net> (permalink) |
| References | <alpine.LNX.2.00.1204031912440.4639@rebelCode.slacknet> <jlfl5o$jn6$1@dont-email.me> |
Followups directed to: comp.lang.c
BartC wrote:
> "rkfb" <rkfb@rebelCode.slacknet> wrote in message
> news:alpine.LNX.2.00.1204031912440.4639@rebelCode.slacknet...
>> I'm reading 'C Programming: A Modern Approach' by KN King.
>>
>> If I run celcius.c (as below) and enter a value of 32 (or 32.0) I am
>> given the equivalent celcius temperature as -2.2. Surely it should be
>> zero?
>
>> celcius = (fahrenheit - FREEZING_PT) * SCALE_FACTOR;
>>
>> printf("Celcius equivalent: ".1f", celcius);
>
> Display the fahrenheit value as well. To check if it is really 32.0. And
> perhaps FREEZING_PT and SCALE_FACTOR (should be 0.555..) while you're
> about it.
>
I'll try BartC but I'm on page 25 and this is only the third program I've
worked through.
--
Robert
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Computed values don't tie up rkfb <rkfb@rebelCode.slacknet> - 2012-04-03 19:29 +0000
Re: Computed values don't tie up James Kuyper <jameskuyper@verizon.net> - 2012-04-03 14:57 -0400
Re: Computed values don't tie up Robert <rkfb1965@googlemail.com> - 2012-04-03 21:37 +0000
Re: Computed values don't tie up Robert <rkfb1965@googlemail.com> - 2012-04-03 21:39 +0000
Re: Computed values don't tie up Ike Naar <ike@iceland.freeshell.org> - 2012-04-03 20:52 +0000
Re: Computed values don't tie up James Kuyper <jameskuyper@verizon.net> - 2012-04-03 16:56 -0400
Re: Computed values don't tie up "BartC" <bc@freeuk.com> - 2012-04-03 22:11 +0100
Re: Computed values don't tie up "BartC" <bc@freeuk.com> - 2012-04-03 21:53 +0100
Re: Computed values don't tie up Robert <rkfb1965@googlemail.com> - 2012-04-03 22:56 +0000
Re: Computed values don't tie up Geoff <geoff@invalid.invalid> - 2012-04-03 20:05 -0700
Re: Computed values don't tie up Martin Ambuhl <mambuhl@earthlink.net> - 2012-04-04 00:38 -0400
Re: Computed values don't tie up "BartC" <bc@freeuk.com> - 2012-04-03 21:04 +0100
Re: Computed values don't tie up Robert <rkfb1965@googlemail.com> - 2012-04-03 21:38 +0000
Re: Computed values don't tie up Kleuske <kleuske@nowhere.net> - 2012-04-03 23:09 +0000
Re: Computed values don't tie up Ben Bacarisse <ben.usenet@bsb.me.uk> - 2012-04-04 04:42 +0100
csiph-web