Created
September 4, 2015 13:23
-
-
Save zhanglun/9fdaa76c89e8e8e718f4 to your computer and use it in GitHub Desktop.
Revisions
-
zhanglun created this gist
Sep 4, 2015 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ UUID(版本4)的形式为: ``` xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx ``` 其中,x 是任意十六进制字符,y 是 8,9,a,b,A,B 其中之一。它的正则表 达式可以写作: ```js /[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89aAbB][a-f0-9]{3}-[a-f0-9]{12}/ ```