geometry - RegEx Pattern for Exactly Three Spaces and Comma Delimited Doubles -



geometry - RegEx Pattern for Exactly Three Spaces and Comma Delimited Doubles -

this odd request, can't seem find examples helping me out. need regex pattern matches following:

(0.0 0.0,1.0 1.0,2.0 0.0,0.0 0.0)

it's triangle on geometric plane each point be:

0.0 0.0 1.0 1.0 2.0 0.0 0.0 0.0

the 4th point beingness original starting point. need regex patter parenthesis, integers, dots, commas , 3 spaces.

use long pattern

\((\d*(?:\.\d+)?\s\d*(?:\.\d+)?),(?!\1)(\d*(?:\.\d+)?\s\d*(?:\.\d+)?),(?!\1)(?!\2)(\d*(?:\.\d+)?\s\d*(?:\.\d+)?),(\1)

demo

regex geometry

Comments

Popular posts from this blog

maven fortify plugin : Unable to load build session with ID XXXXX .. See log file for more details -

c# - Primavera WebServices does not return any data -

android - Display emoji panel with genymotion - keyboard/touch input? -