0

I've plenty fill and want to find all of them which are like this:

A = A + B

So I wanna use a regular expression using M + x rgrep. and was thinking to something like that: ([A-Za-z][A-Za-z0-9]*) = () + [A-Za-z][A-Za-z0-9]* where () create a group which can be used latter.

Their is a way to make a regular expression where two item must be the same but without knowing the form of them?

Jason Aller
  • 3,541
  • 28
  • 38
  • 38
Romain Picot
  • 255
  • 1
  • 13

1 Answers1

1

I think you want something like this,

([A-Za-z][A-Za-z0-9]*) = \1 \+ [A-Za-z][A-Za-z0-9]*

DEMO

Avinash Raj
  • 172,303
  • 28
  • 230
  • 274