Endings and Automatons