automatically calculate string mathematical expressing in C#
<p>I have a C# string which is representation of a mathematical expression, something like this:</p>

<pre><code>A = (B*0.25)+(D*0.25)+(1-W)
</code></pre>

<p>how can I calculate value of A? should I manually parse all characters, then perform my calculation? Although it is possible but I think it would be time-consuming to write such a code, is there any way that C# can understand this string and calculate value of A (of course I would declare A, B, D &amp; W as variables</p>

<p>thanks</p>
