101-400 Exam QuestionsBrowse all questions from this exam

101-400 Exam - Question 55


In the vi editor, how can commands such as moving the cursor or copying lines into the buffer be issued multiple times or applied to multiple rows?

Show Answer
Correct Answer: B

In the vi editor, you can repeat commands multiple times or apply them to multiple rows by specifying the number right in front of the command. For example, to move the cursor to the right by four characters, you would use '4l', and to copy two lines into the buffer, you would use '2yj'. Preceding a command with a number determines how many times the command will be executed.

Discussion

1 comment
Sign in to comment
DuboisNicolasDuclairOption: B
Oct 21, 2023

In the vi editor, commands such as moving the cursor or copying lines into the buffer can be issued multiple times or applied to multiple rows by: B. By specifying the number right in front of a command such as `4l` or `2yj`. For example, if you want to move the cursor to the right by 4 characters, you can type `4l`. If you want to yank (copy) 2 lines downward, you can type `2yj`. Preceding a command with a number specifies how many times the command should be repeated.