Anonymous user
Continued fraction/Arithmetic/Construct from rational number: Difference between revisions
Continued fraction/Arithmetic/Construct from rational number (view source)
Revision as of 20:04, 10 March 2013
, 11 years ago→{{header|REXX}}: changed a comment in the REXX section header. -- ~~~~
m (→{{header|REXX}}: Separated the rambling paragraph to make it more readable, then sentences are disjoint enough to warrant their own paragraphs. -- ~~~~) |
m (→{{header|REXX}}: changed a comment in the REXX section header. -- ~~~~) |
||
Line 226:
<br>The subroutine '''$maxfact''' was included and is only needed if the number used for '''r2cf''' is a decimal fraction.
<br>Checks were included to verify that the arguments being passed to '''r2cf''' are indeed numeric and also not zero.
<br>This version also handles negative numbers.
<lang rexx>/*REXX pgm converts decimal or rational fraction to a continued fraction*/
numeric digits 230 /*this determines how many terms */
|