Convert Java to C# (Unity)
<p>I'm trying to convert <a href="http://introcs.cs.princeton.edu/java/43stack/Evaluate.java.html" rel="nofollow">this Java code</a> (Evaluates arithmetic expressions using Dijkstra's two-stack algorithm) to C# :</p>

<pre><code>using System;
using System.Collections.Generic;
using System.IO;

public class Evaluate
{
    public double Eval(string expression)
    {
        Stack&lt;string&gt; ops = new Stack&lt;string&gt;();
        Stack&lt;double&gt; vals = new Stack&lt;double&gt;();

        string s = expression;
        while (!s.Equals(""))
        {
            if (s.Equals("(")) ;
            if (s.Equals("+")) ops.Push(s);
            else if (s.Equals("-")) ops.Push(s);
            else if (s.Equals("*")) ops.Push(s);
            else if (s.Equals("/")) ops.Push(s);
            else if (s.Equals("sqrt")) ops.Push(s);
            else if (s.Equals(")"))
            {
                string op = ops.Pop();
                double v = vals.Pop();
                if (op.Equals("+")) v = vals.Pop() + v;
                else if (op.Equals("-")) v = vals.Pop() - v;
                else if (op.Equals("*")) v = vals.Pop() * v;
                else if (op.Equals("/")) v = vals.Pop() / v;
                else if (op.Equals("sqrt")) v = Math.Sqrt(v);
                vals.Push(v);
            }
            else vals.Push(double.Parse(s));
        }
        return vals.Pop();
    }
}
</code></pre>

<p>But Unity stop working when I'm try to test it. What have I done wrong?</p>