Esempio n. 1
0
        protected override void Run()
        {
            BinaryCompleteNode <string> root = new BinaryCompleteNode <string>("/", new BinaryCompleteNode <string>("+", new BinaryCompleteNode <string>("5"), new BinaryCompleteNode <string>("5")), new BinaryCompleteNode <string>("+", new BinaryCompleteNode <string>("0.25"), new BinaryCompleteNode <string>("0.25")));

            Console.WriteLine("The operations tree:");
            root.PrintTree();

            double result = IntNodeEvaluation(root);

            Console.WriteLine("Result: {0}.", result);
        }