Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
例として、Banjo.ald:Mandolin.ald:Guitar.tst という文字列があり、文字列 Guitar を返す正規表現を見つけようとしています。上記の例では、関心のあるテキストの前に 2 つのグループがあります (つまり、Banjo.ald:Mandolin.ald:) が、実際には、グループが Banjo.ald として定義されているこれらのグループが 1 ~ N 個あります。
私が探しているものをもっと明確にする必要がある場合はお知らせください。
最後のコロンまですべてを消費する貪欲な正規表現を使用できます。次に、次の単語までのすべてをキャプチャします.tst。
.tst
^.*:(.*).tst$