• + 0 comments

    \1 refers to the what was found within the first capture group. Capture groups are groups incased inside parentheses >>()<<

    In the context of >> grep -P '([0-9]) ?\1' << the \1 would mean whatever was found within the ([0-9]). This would satisfy the "duplicate" portion of the problem.