Condition check from string

even then it will be a string, how will you validate the condition