Advertisement
Guest User

Untitled

a guest
Jun 26th, 2019
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. def mutation_detector(DNA1,DNA2):
  2. """recieves 2 DNA sequences and compare for mutations, return the first
  3. index in which a mutation has been detected and -1 if there are no mutations"""
  4. if sequence_check(DNA1)=="Wrong input" or sequence_check(DNA2)=="Wrong input":
  5. return "Wrong input"
  6. if len(DNA1)!=len(DNA2):
  7. return "Wrong input"
  8. for i in range(len(DNA1)):
  9. if DNA1[i]!=DNA2[i]:
  10. return i
  11. return -1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement