A+B: Difference between revisions

2 bytes removed ,  10 years ago
Line 1,344:
 
=={{header|Frink}}==
This program handles arbitrarily-large integers, or even floating-point or rational numbers or complex numbers (as long as they're not internally separated with spaces.) It can even handle units of measure (with no embedded spaces) such as "3.3meter + 2feet" and do the right thing. It can handle any number of arbitrary whitespace characters separating the numbers. It also works whether the input is user-interactive, or input comes from stdin.
<lang frink>
sum[eval[split[%r/\s+/, input[""]]]]
494

edits