[plt-scheme] DrScheme Can't Insert Negative Fractions?
Did you accidentally add 7/9 to -17? That would give you -16 2/9, as
you saw. You need to remember to subtract the 7/9, because it's
negative too. Or add -7/9.
On Sun, Aug 31, 2008 at 12:01 PM, Grant Rettke <grettke at acm.org> wrote:
> This message was originally posted here:
> http://groups.google.com/group/study-htdp/browse_thread/thread/4be081a64769dcfb
> by my friend Kartik.
> I cross-posted it on his behalf so that he might have an answer in the
> morning (his time). BTW, we haven't discussed check-result and
> check-within, yet.
> ;;
> While attempting to solve fahrenheit to celsius problem I was trying
> to add a simple test which tests the following condition
>
> (= (fahrenheit-to-celsius 0) -17 7/9)
>
> DrScheme allows adding fractions via Menu->Special->Insert Fraction.
> However, when I try inserting a fraction for -17 7/9 it gets converted
> to -16 2/9.
>
> Is this a bug? 17 7/9 by itself gets added properly but not its
> equivalent negative value.