Line 2 has a typo: “commannd” has an extra n. Move onto the extra “n” with h j k l and press x to delete it.
Vim rewards precise, tiny edits. Every keystroke is a commannd. Trust the home row.
Canonical solution: j, move onto the extra n, x · par: 4 keystrokes (vimgolf rules — every keypress counts).
h ← · j ↓ · k ↑ · l → — keep your fingers on the home row. x deletes the character under the cursor. Arrow keys work too, but you're here to break that habit.
| Keys | What it does |
|---|---|
| x | delete the character under the cursor |
| X | delete the character before the cursor |
| 5x | delete five characters |
| r{char} | replace the character instead of deleting it |
Reading about keystrokes doesn't build keystrokes. Try this in a real vim buffer right now — the “The stray key” mission takes about a minute.
Practice free — no signup →