I am creating a game that lets the player enter input, changes some states, then checks if a \"goal value\" is true (obviously this description is muchly simplified), and I
There's no standard way to do it in C++. One solution is to write your own parser.
Another solution, that I'd recommend: embed a Lua interpreter in your program. Lua is a simple yet powerful programming language, that also has an extremely lightweight (<300kB) and easy-to-use interpreter. Read an introductory article here: http://www.ibm.com/developerworks/linux/library/l-embed-lua/index.html
Having Lua embedded in your game has a number of nice side advantages: