Regex: Select and delete only the first word at the beginning of each line

I want to select and delete only the first word at the beginning of each line

For example:

My favorite flower is yello.
I love cars.
Book and flowers are my game.

The Output should be:

favorite flower is yello.
love cars.
and flowers are my game.

Solution 1:

  • Ctrl+H
  • Find what: ^\S+\h*(.*$)
  • Replace with: $1
  • CHECK Wrap around
  • CHECK Regular expression
  • UNCHECK . matches newline
  • Replace all

Explanation:

^           # beginning of line
\S+         # 1 or more non space
\h*         # 0 or more horizontal spaces
(.*$)       # group 1, rest of the line

Replacement:

$1          # content of group 1

Screenshot (before):

enter image description here

Screenshot (after):

enter image description here