One of Vim’s great strengths, of course, is the variety of movements that make commands like change so powerful. For example,
b move the cursor to the beginning of the next word or the previous one (“before”),
e to the end of the current word. Round brackets lead to the previous or next sentence beginning, the curly brackets to paragraph endings.
$ point to the beginning or end of the line.
fy moves us to the next “y” (“following”),
ty to the character directly before it (“till”).
T do the same only backwards.
G takes the cursor to the top of the document,
H to the first character on the screen,
gg goes all the way to the bottom. If there is a bracket in the current line,
% jumps to the counterpart. And then you can still jump to search results.
n would be the next search result,
N searches backwards. Speaking of which, you start searches with the forward slash
* looks for the next occurrence of the word under the cursor in the document, the hash
# does likewise, only backwards.
If you want to jump to the beginning of a special line, you can do this with
N corresponds to the line number. Thus, :42 jumps to the beginning of line 42. You can have the line numbers displayed with
Last but not least I can set marks and move between them.
ma marks the current line as jump tag “a”, with
'a I can move there anytime. Jump marks that are labeled with capital letters are global, so they may open the file in which they are stored.