Last active
April 8, 2019 08:11
-
-
Save StephenFordham/b5b756f415bf1e3f85b1cbeaa0fda037 to your computer and use it in GitHub Desktop.
Getting started with re.search
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 | |
DNA = 'GAGCGCTAGCCAAA' | |
match = re.search(pattern='AAA', string=DNA) | |
# match = re.search('AAA', 'DNA') | |
print(match) | |
<re.Match object; span=(11, 14), match='AAA'> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment