HedgeServ Interview Question

given the string ("1 + 2") write a function that solves it.