Can regex match be based on two lines of text?

后端 未结 2 1307
逝去的感伤
逝去的感伤 2021-01-19 00:32

Let\'s say I have

def
abc
xyz
abc

And I want to match

xyz
abc

<
2条回答
  •  野的像风
    2021-01-19 01:06

    Many regex implementations allow explicit line terminators. If \n is the line separator, then just search for xyz\nabc.

提交回复
热议问题