home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / vol_100 / 111_01 / bcreview.doc < prev    next >
Text File  |  1985-08-21  |  2KB  |  42 lines

  1.             A REVIEW OF BC
  2.  
  3.      BC evaluates mathematical expressions entered at the
  4. console, and prints the numerical values.  Expressions may
  5. contain integers, arithmetic and logical operators, and
  6. parentheses.  All results are integers ranging from 0 to 65535,
  7. and are printed in decimal, hexadecimal, octal, and binary
  8. formats.
  9.  
  10.      BC offers to print instructions when it first starts.  If
  11. you accept the offer, BC quickly prints more than can be dis-
  12. played on most CRT terminals, so you need to be ready to use
  13. the control-s key.  BC then prompts for the first expression.
  14. While you are entering expressions, the usual CP/M line editing
  15. functions work, so you can easily correct entry errors, or
  16. start over.  When a carriage return is entered, BC evaluates
  17. the expression, prints the result, and prompts for another
  18. expression.  Expression evaluation seems instantaneous,
  19. and appeared to be accurate in the few cases tested.
  20.  
  21.      Operator precedence is strictly left-to-right, which
  22. produces unexpected results unless extra parentheses are used
  23. to force BC to use the operators in the normal order.
  24. The exclusive-OR logical operator (~) does not work; it
  25. produces an error message.  Also, while the instructions
  26. state that hexadecimal, octal, and binary numbers may be
  27. entered, there are no instructions for entering such numbers,
  28. and I was unable to hit upon the method.  All numbers I
  29. entered were interpreted as decimal numbers.
  30.  
  31.      BC tolerates operator errors without falling apart, but is
  32. not always helpful in identifying errors.  It tells you if you
  33. have unbalanced parentheses, but doesn't always tell you if
  34. you use an operator that it doesn't recognize.
  35.  
  36.      The documentation file, BC.DOC provides clear and correct
  37. instructions for compiling, and lists the files needed.
  38.  
  39.  
  40. John M. Smith
  41. CUG Librarian for the Utilities IV diskette
  42.