Text Objects · Words
Words Review
Mix motion-based and object-based word edits.
Use a motion when the edit starts at the cursor and travels; use a text object when the current word itself is the subject.
Use dw, daw, diw, and ciw in the editor beside this lesson. The challenge proves it once; Practice is a timed run against the clock.
Keys in this lesson
- dw
- Delete from the cursor to the next word start
- daw
- Delete the word under the cursor and its trailing space
- diw
- Delete the word under the cursor, leaving the spaces
- ciw
- Change the word under the cursor from anywhere inside it
Practice against the clock.
The challenge proves completion once. Practice is a timed run of 15 goals — beat par, then beat your own best time. Every completed goal saves locally.