edited program, now shows index of non-text symbols