Created
February 22, 2009 20:24
-
-
Save jroo/68602 to your computer and use it in GitHub Desktop.
extract GAO report ID's from text and return as a list
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
import re | |
#extract GAO report ID's from text and return as a list | |
def extract_gao_id(haystack): | |
p = re.compile('GAO-\d{2}-?\d{1,4}\w?') | |
needle_list = p.findall(haystack) | |
return needle_list |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment