added Result class (holds value or error message)
added Config class