ã³ã¼ãã¸ãã¯ã¼ã«æ¦ãå å¶ç¹ãã¾ãããã RubyãPerlã®ãããªæ£è¦è¡¨ç¾ãæ¼ç®åãªã¼ãã¼ãã¼ãã§å®ç¾ããã¢ã¤ãã£ã¢ããããªæãã let phoneNumber = "(800) 555-1111" if phoneNumber =~ "(?\\d{3})?\\s\\d{3}-\\d{4}" { println("That looks like a valid US phone number") } ããæãã æ¨æºãªããããªæããObjCã»ã©é¢åã§ã¯ç¡ããã¾ã åé·ã if let match = name.rangeOfString("ski$", options: .RegularExpressionSearch) { println("\(name) is probably polish") } Regex in Swift - Ben Scheirman
{{#tags}}- {{label}}
{{/tags}}