Practice - 5 Tasks
Answer the questions below
1fill in blank
easyComplete the code to enter insert mode in vim.
Linux CLI
vim filename.txt
Press [1] to start typing. Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Pressing ':w' which is for saving, not inserting.
Pressing ':q' which quits vim.
Pressing 'x' which deletes a character.
✗ Incorrect
Pressing 'i' in vim switches to insert mode so you can start typing text.
2fill in blank
mediumComplete the command to save changes in vim.
Linux CLI
In command mode, type [1] and press Enter to save the file.
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using ':q' which quits without saving.
Using ':i' which is for insert mode.
Using ':x' which saves and quits but is not just save.
✗ Incorrect
The ':w' command writes (saves) the changes to the file.
3fill in blank
hardFix the error in the command to quit vim without saving.
Linux CLI
Type [1] and press Enter to quit without saving.
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using ':wq' which saves and quits.
Using ':x' which saves and quits.
Using ':w' which only saves.
✗ Incorrect
The ':q!' command quits vim without saving any changes.
4fill in blank
hardFill both blanks to save and quit vim in one command.
Linux CLI
Type [1][2] and press Enter to save and quit.
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using ':x' which saves and quits only if modified.
Using ':q!' which quits without saving.
Using ':w!' which forces save but not quit.
✗ Incorrect
Typing ':wq' saves the file and quits vim.
5fill in blank
hardFill all three blanks to save and quit vim with a single command that forces saving.
Linux CLI
Type [1][2][3] and press Enter to save and quit forcefully.
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using ':x!' which updates and quits forcefully if modified.
Using ':q!' alone which quits without saving.
Using ':w!' which saves but does not quit.
✗ Incorrect
The ':wq!' command saves and quits vim forcefully.