Created
May 25, 2019 15:42
-
-
Save brydavis/25f1914f90013c620337a8abc94fee12 to your computer and use it in GitHub Desktop.
This file contains 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 characters
package main | |
import ( | |
"fmt" | |
"log" | |
"regexp" | |
) | |
func main() { | |
reg, err := regexp.Compile("[^a-zA-Z0-9]+") | |
if err != nil { | |
log.Fatal(err) | |
} | |
s := reg.ReplaceAllString("A MAN'DER RYN-NOLD", "") | |
fmt.Println(s) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment