improving char counter examples