Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on 0.3 - 0.2 == 0.2 - 0.1 is falsy. Which language gets this right?.
Fortran (the oldest still in use):
$ cat sub.f C Prints 0.3-0.2 and 0.2-0.3 PRINT 4, 0.3-0.2, 0.2-0.1 4 FORMAT ('0.3-0.2=',F3.1,' 0.2-0.1=',F3.1) STOP 1 END $ gfortran sub.f -o sub $ ./sub 0.3-0.2=0.1 0.2-0.1=0.1 STOP 1 $
cl-user> (values (- 3/10 2/10) (- 2/10 1/10)) 1/10 1/10
$ cat sub.cob IDENTIFICATION DIVISION. PROGRAM-ID. DIFFERENCE. ENVIRONMENT DIVISION. INPUT-OUTPUT SECTION. FILE-CONTROL. DATA DIVISION. FILE SECTION. WORKING-STORAGE SECTION. 77 out32 pic 9.9. 77 out21 pic 9.9. PROCEDURE DIVISION. subtract 0.2 from 0.3 giving out32. subtract 0.1 from 0.2 giving out21. display '; 0.3 - 0.2 = ' out32 . display '; 0.2 - 0.1 = ' out21 . goback. $ cobc -fixed -Wcolumn-overflow -Wparentheses -x sub.cob $ ./sub ; 0.3 - 0.2 = 0.1 ; 0.2 - 0.1 = 0.1 $
Fortran (the oldest still in use):
Lisp (the second oldest still in use): Cobol (the third oldest still in use):