Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
Check out the new SourceForge HTML5 internet speed test! No Flash necessary and runs on all devices. ×
Programming

Submission + - Building Expression Evaluator with Expression Trees in C# – Part 1 (aboutmycode.com)

An anonymous reader writes: This is first part of a series about writing expression evaluator in C#. Even though there are several of them available already I decided to write my own as this one is based on expression trees and is very simple. The evaluator supports numeric expressions as well as expression with parameters.

In this part we will build a simple expression evaluator which will support expressions like this: “2+2, “2.7+3.2, “1.7+2.9+14.24+6.58, “84+15+4-4*3*9+24+4-54/3-5-7+47, “25/3+1.34*2.56+1.49+2.36/1.48, etc. It will however not be able to parse expression with parentheses or with variables. These features will be implemented in the coming posts.

This discussion was created for logged-in users only, but now has been archived. No new comments can be posted.

Building Expression Evaluator with Expression Trees in C# – Part 1

Comments Filter:

FORTRAN is not a flower but a weed -- it is hardy, occasionally blooms, and grows in every computer. -- A.J. Perlis

Working...