PYTHON FUNCTION FUNCTION FOR DNA SEQUENCES
def is_valid_sequence(dna): ”'(str) -> bool Return True if dna sequence is valid >>>is_valid_sequence(‘AAAAA’) True >>>is_valid_sequence(‘TTTTT’) True >>>is_valid_sequence(‘CCCCC’) True
Read moredef is_valid_sequence(dna): ”'(str) -> bool Return True if dna sequence is valid >>>is_valid_sequence(‘AAAAA’) True >>>is_valid_sequence(‘TTTTT’) True >>>is_valid_sequence(‘CCCCC’) True
Read moredef get_length(dna): ”’ (str) -> int Return the length of the DNA sequence dna. >>> get_length(‘ATCGAT’) 6 >>>
Read more