Doesn't that depend on what you mean by "handles booleans"?
This is legal C:
#include <stdio.h>
main() {
if (2) {
printf("hello\n");
}
}
In a C if statement, all non-zero numbers are treated the same way
(and the fussy sort of precision needed to even discuss this issue is,
ironically, an important part what leads to this sloppy use of the
term "boolean").
--
Raul
On Thu, Oct 23, 2014 at 6:37 PM, Jon Hough <[email protected]> wrote:
> Doesn't J handle booleans the same as C, i.e. 0,1?
> If not, how do APL/J handle booleans?
>
> --- Original Message ---
>
> From: "Devon McCormick" <[email protected]>
> Sent: October 24, 2014 2:30 AM
> To: "Chat forum" <[email protected]>
> Subject: [Jchat] Characterizing how J and other APLs handle Booleans
> distinctly from most languages
>
> Hi -
>
> While looking at the Wikipedia entry on "Boolean data type" recently, I
> noticed that the APL family is - as usual - unrepresented. Since I was
> looking here because of the maddening arbitrariness with which Booleans are
> handled in other languages, it occurs to me that the much cleverer handling
> of Booleans characteristic of the APL world should be given a higher
> profile.
>
> So, any ideas on a Wikipedia entry for "APL, J" handling of Booleans?
>
> Thanks,
>
> Devon
>
> --
> Devon McCormick, CFA
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm