in reply to Validating Comma Delimited String

  $string =~ /^\d{4}(?:\,\d{4})*$/

... start, 4 digits, then any number of comma followed by 4 digits up to end (and then stop).

... and having validated, then you can split(/,/, $string) to "capture" the numbers.