美文网首页
2022-09-16 ROSALIND_1: Counting

2022-09-16 ROSALIND_1: Counting

作者: 小孟在充电 | 来源:发表于2022-09-16 14:28 被阅读0次
    # ----ROSALIND_1: ----
    # Counting DNA Nucleotides
    
    with open("1_rosalind_dna.txt") as file_object:
        seq = file_object.readlines()
        seq = [x.strip("\n") for x in seq]
    
    def get_count(seq):
        seq = str(seq)
        base = "ACTG"
        for i in base:
            print(seq.count(i), end = " ")   
    

    相关文章

      网友评论

          本文标题:2022-09-16 ROSALIND_1: Counting

          本文链接:https://www.haomeiwen.com/subject/hwujortx.html