Information Extraction - AACRM Exercise


Files for the African-American Civil Rights Exercise

civil_rights_assign.txt
aacrm_text.txt
civil_rights_solution.pl
civil_rights_multiple_dates.py
examples_sort_grep.txt


You can start by running the perl program:
cat aacrm_text.txt | perl civil_rights_solution.pl > result.txt


There is a nice tutorial on perl regular expressions here: http://perldoc.perl.org/perlretut.html


For python, see here (note that python uses perl regular expression syntax): https://docs.python.org/2/howto/regex.html

You can also use the flag --perl-regexp with grep (NOT egrep!) to get a similar syntax to perl regular expressions in grep