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.0the 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
Post a Comment