title: How I can check for a valid date format in Perl?
body: <p><br> I am getting a date field from the database in one of my variables, at the moment I am using the following code to check if the date is in "yyyy-mm-dd" format</p>
  
  <pre><code>if ( $dat =~ /\d{3,}-\d\d-\d\d/ )
  </code></pre>
  
  <p>My question, is there a better way to accomplish this.</p>
  
  <p>Many Thanks</p>