Drill 02: WORD Motions & Operators
Master the difference between w and W, combined with operators.
Prerequisites
Complete Session 02: WORD Motions & Operators first.
Practice Text
hello-world.example.com user@domain.org /etc/ssh/config function(arg1, arg2) myVariable_name config["key"]
Drill Exercises
Exercise 1: Navigate with w vs W
Starting at beginning of each line:
1. Count w presses to reach end
2. Count W presses to reach end
3. Feel the difference
Exercise 2: Delete with dw vs dW
-
dwon "hello-world" - observe what’s deleted -
dWon "hello-world" - observe what’s deleted -
d3w- delete 3 words -
d2W- delete 2 WORDs
Exercise 3: Change operations
-
cWon an email address - change the whole thing -
ciwon a variable name - change just the word -
c2w- change 2 words
Exercise 4: Operator pending
Practice the grammar:
1. Press d, pause, then w
2. Press c, pause, then W
3. Press y, pause, then 2w
Self-Assessment
| Skill | Comfortable? |
|---|---|
|
[ ] Yes [ ] Need practice |
|
[ ] Yes [ ] Need practice |
Counts with motions |
[ ] Yes [ ] Need practice |