Mission 19 / 52• Advanced Vertical Movement
Relative Line Jumps
Every movement in Vim can be preceded by a count. `3j` moves down 3 lines; `5k` moves up 5 lines.
Modern Vim setups use relative line numbers so you can glance at any line and immediately see the exact count needed to reach it.
Counted line jumps
- 3jjump down 3 lines
- 2kjump up 2 lines
- 4wjump forward 4 words
1// Line 0: Header2const port = 3000;3const host = "localhost";4const env = "development";5const ssl = false;6// Line 5: FooterFrom the top line, press `3j` or `4j` to jump directly down several lines in one tap.
Now it's your turn!
- Navigate to each green target across the code snippet.
- Use the motions and techniques learned in this lesson to land accurately on each target.
- See how fast you can complete 10 targets.
0/10
1// Line 0: Header2const port = 3000;3const host = "localhost";4const env = "development";5const ssl = false;6// Line 5: FooterNORMAL
00:00
NextCtrl+jAbsolute Line Jumps