#include #include "uCalc.h" using namespace std; using namespace uCalcSoftware; int main() { uCalc uc; // 1. Parse the expression string once to create a reusable object. //var expr = uc.Parse("5 * 10"); { uCalc::Expression expr("5 * 10"); expr.Owned(); // Causes expr to be released when it goes out of scope // 2. Evaluate the pre-parsed object as many times as needed. cout << expr.Evaluate() << endl; cout << expr.Evaluate() << endl; } // The expression object is automatically released here. }