Skip to content

Latest commit

 

History

History
7 lines (6 loc) · 697 Bytes

File metadata and controls

7 lines (6 loc) · 697 Bytes

Arithmetic-expression-evaluation-

A simple java program which evaluate the result for an arithmetic expression. It also supports floating-point numbers along with decimal numbers. The expression can contains parentheses (you must balance the parentheses) and the binary operator like +,-,/,* along with the ^(power operator). Give the input expression in the form of string.

Usage

  • Use the test.java file as the driver file where you can pass the your arithmetic expression.
  • Call the evaluate function and pass the expression as argument in the form of string to get your result.
  • Two examples were provided in the test.java file, have a look at it and change it according to your need