The stupid question is the question not asked | |
PerlMonks |
Re: Coordinate validatorby FreeBeerReekingMonk (Deacon) |
on Jun 10, 2019 at 13:03 UTC ( [id://11101197]=note: print w/replies, xml ) | Need Help?? |
I like the comma_count solution, you checked all bordercases. Maybe offer a perlgolf competition on this code :) Particularly this code ($comma_count==3): s/(,)/!--$n ? '.' : $1/ge; I liked that approach. Found a bug though. This one is successful, but gives a bad coordinate back:
In Section
Cool Uses for Perl
|
|