def readFirstSequenceFasta(filename):
    """Returns first sequence from a file."""
    fasta = open(filename)
    seq = []
    title = ''
    first = True
    for line in fasta:
        if line[0] == '>':
            if first:
                title = line[1:].strip()
                first = False
            else:
                break
        else:
            seq.append(line.strip())
    fasta.close()
    return title, ''.join(seq)
