[R] a < b < c is alway TRUE

Till Baumgaertel till.baumgaertel at epost.de
Fri Jul 6 16:57:03 CEST 2001

> Why would you expect 1 > 1 to be True?
i didnt't realize TRUE<-1

i thought TRUE was something like INF or so, because normally the following is 
false (like Duncan wrote):
> In R like C, FALSE is 0 and TRUE is 1

normally in C you define somewhat like
#define FALSE ((unsigned long) 0)
#define TRUE (~((unsigned long) 0))
(ok, there are more aesthetic ways, you can use "signed",...)

but using binary negation makes much sense in many ways. so in C TRUE evaluates 
to max( long) (if you use the unsigned variant), and in fact i thought this 
would be the implementation in R as well...


"I have seen things you people wouldn't believe.
Attack-ships  on fire off the shoulder of Orion.
I watched seabeams glitter in the dark near the 
Tannhauser gate.
All  those  moments  will  be lost in time like
tears in rain. Time to die."              (Roy)
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch

More information about the R-help mailing list