Monday, July 22, 2013

I've been sick.  I had to take some time off.  I'm caught up on Computation Molecular Evolution but am still a week behind on Coding the Matrix.  I did a few more Rosalind problems but am currently stumped on one of them.  It seems quite simple and I'm sure my answer is correct based upon my understanding of the problem.  I've learned a lot about recursive programming in python.  I've also learned a bit about markdown.  Here's the function Rosalind doesn't accept:

def lev(lex,len,txt=''):
    for x in lex.split(' '):
        yield txt+x
        if len > 1:
            for y in lev(lex,len-1,txt+x):
                yield y

[x for x in lev('T C A G',3)]

I guess I still need to relearn html so I can set code blocks off more than I've just done.

No comments:

Post a Comment