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.
私はこの正規表現を持っています:
"\\(d+)(,)\\(w+)(,)\\(w+)(,)\\(w+)(,)\\(\")(d+)(,)(d+)(.)(d+)(\")(,)\\(w+)(,)\\(w+)(,)\\(w+)";
そして、私はこのメッセージを受け取っています:
インデックス 3 付近の終了 ')' が一致しません
私の正規表現の何が問題なのか、誰かが私にヒントを教えてもらえますか?
最初の括弧をエスケープしていますが (その意味はリテラルになります)、次の括弧はエスケープしていないため、無効な正規表現です。
"\\(d+)(,) ^ ^ | | --+- // You have escaped this one... | - // ...but not this one.
あなたの代わりに、\\(d+)おそらく望んでいた(\\d+)か、それ以上\\d+です。\\影響し(ないため、エラーが発生していdます。
\\(d+)
(\\d+)
\\d+
\\
(
d