Learning the vi Editor/Moving around

We can move around in the editor by first entering command mode, and then using the, , , and keys.


 * Note: your arrow keys may be set up to work, and you can use them if you like, but for proficiency and for advanced work later, you should learn to use the letter keys.


 * The key, in command mode, moves the cursor one character left.
 * The key, in command mode, moves the cursor one character down.
 * The key, in command mode, moves the cursor one character up.
 * The key, in command mode, moves the cursor one character right.

If you have trouble remembering this, keep in mind that is leftmost, the letter goes down below the line, the letter pokes up above the line, and the  key is rightmost. (J also resembles an arrow pointing downward, if you squint a bit.)

After you have moved the cursor using those keys, you can enter insert mode again by pressing. When you do this, you insert text at the cursor, inserting text between the character to the left of the cursor and the current position of the cursor. Let's practice this in an exercise.