Reputation: 11592
I want to calculate mathematical expression in java6.for example,
c=a*b+((b/d)-c)/100-(h/2)
How to evaluate this math expression....
Please guide me get a solution...
Saravanan.P
Upvotes: 3
Views: 240
Reputation: 17761
i recently implemented a simple math expression evaluator on basis of Dijkstra's Shunting Yard Algorithm and released it under the Apache License 2.0.
you can check it out here: http://projects.congrace.de/exp4j/index.html
Upvotes: 1
Reputation: 53536
By the way, JEP can still be downloaded (through an older version, but still) as a GPL licensed library here (See related question.)
** EDIT **
The JEP documentation is very well-written and contains a lot of examples.
Upvotes: 1