RosettaCodeData/Task/Fractran/APL/fractran-1.apl

12 lines
338 B
APL
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

fractran{
parts ' '
frac ¨'/'
simp ÷/
mul simp×
prog simpfrac¨parts
step {(1=2¨next)/next mul¨( 1)}
(start nstep)
rslt (,progstep)nstep¨start
((/)(\0))rslt
}