Created
September 27, 2023 16:33
-
-
Save daviddamilola/9b1c7b0ffe20c6b44f064f401eae6c65 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
testInput = 'AAAACCCGGT' | |
def getReverseComplement (DnaString): | |
allowedTypesMap = {'A': 'T', 'G': 'C', 'T':'A', 'C': 'G'} | |
result = [allowedTypesMap[char] for char in (DnaString)] | |
return ("".join(result))[::-1] | |
print(getReverseComplement(testInput)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment