I like this "best effort" handling, even given bad input.