Takes a sentence as input specifying an arithmetic expression and calculates it.