Arithmetic evaluation: Difference between revisions

m
m (→‎Icon and Unicon: notes, spelling)
Line 21:
 
=={{header|ALGOL 68}}==
{{works with|ALGOL 68|Revision 1 - no extensions to language used}}
 
{{works with|ALGOL 68G|Any - tested with release [http://sourceforge.net/projects/algol68/files/algol68g/algol68g-1.18.0/algol68g-1.18.0-9h.tiny.el5.centos.fc11.i386.rpm/download 1.18.0-9h.tiny]}}
{{wont work with|ELLA ALGOL 68|Any (with appropriate job cards) - tested with release [http://sourceforge.net/projects/algol68/files/algol68toc/algol68toc-1.8.8d/algol68toc-1.8-8d.fc9.i386.rpm/download 1.8-8d] - A68RS has not implemented forward declarations}}
<lang algol68>INT base=10;
MODE FIXED = LONG REAL; # numbers in the format 9,999.999 #
Line 156 ⟶ 160:
);
 
test:(
# TEST #
printf(($" euler's number is about: "g(-long real width,long real width-2)l$,
EVAL build ast("1+1+(1+(1+(1+(1+(1+(1+(1+(1+(1+(1+(1+(1+(1+1/15)/14)/13)/12)/11)/10)/9)/8)/7)/6)/5)/4)/3)/2")));
SKIP EXIT
index error:
printf(("Stack over flow"))</lang>
)</lang>
Output:
<pre>
<lang algol68> euler's number is about: 2.71828182845899446428546958</lang>
</pre>
 
=={{header|AutoHotkey}}==
{{works with|AutoHotkey_L}}