home *** CD-ROM | disk | FTP | other *** search
/ Simtel MSDOS - Coast to Coast / simteldosarchivecoasttocoast2.iso / calculat / sm30a.zip / SYMBMATH.H13 < prev    next >
Text File  |  1993-11-07  |  654b  |  15 lines

  1.         3.3.4  Conditional 
  2.     There are two conditional functions:
  3.         if(test then x)
  4.         if(test then x else y)
  5. if(condition then x)            gives x if condition evaluates to 1, or no 
  6.                 output otherwise.
  7. if(condition then x else y)     gives x if condition evaluates to 1, y if 
  8.                 it evaluates to 0, or no output if it 
  9.                 evaluates to neither 1 or 0.
  10. The 2 words (then and else) can be replaced by comma ,.
  11.       It is useful in definition of the use-defined function to left the
  12. function unevaluted if the argument of the function is not number.
  13. e.g. define f(x_):=if(isnumber(x), 1), then call f(x), f(10) gives 1, 
  14. and f(a) gives f(a).
  15.