refactoring to new input method algorithm: do not use repeat count numbers