in reply to Perl and maths

What do you mean, "produce Perl line by line"? (5/3 + 7/13)/(5/2-3/7) and (39 + 3/13)/(35-9/21) are valid Perl expressions.

Replies are listed 'Best First'.
Re^2: Perl and maths
by ReinhardE (Sexton) on Feb 15, 2005 at 11:06 UTC
    I admit, I was not clear
    You remember at school ?
    The teacher gave you an expression
    and you transformed it step by step into
    a simpler one
    , at the end remained a "nice" result
    or at least it should ....
    That's what I'm trying to simulate ..
    cheers
    reinhard

      I believe you mean you would like to have perl 'simplify' the expression. Although, typically these expressions have variables. On the other hand, is this to teach 'order of operations'?

      Neil Watson
      watson-wilson.ca