I have some strings like this: 2012-02-05T07:42:47.000Z mixed with other strings. It is always in this format. (but the numbers are not the same, of course…the times are different)
(not Sun, 05 Feb 2012 07:42:47 GMT)
I want to know whether a string matches that format. How can I determine that? It’s so complicated with the colons and dots and stuff.
Regex
[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}\.[0-9]{3}Z