Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Too many memory allocations
You can make output array at start
Cause u know amount of elements len(arr) * len(arr[0])
But very elegant
very elegant
He calls the replace(). Replace accepts something called a regex (which tells your replace method to expect a certain type of string pattern -- in this case the regex is a '.' which ensures your input is any character but a line terminator). The second parameter replace accepts is a callback function. The callback function contains a dictionary of matching DNA values. This function runs on each individual character from the original dna string and 'replaces' it with the matching DNA value from the dictionary.
haha wow, solid and suprisingly readable
i'm not french either, but it's an adapted term for admitting defeat, sure to be in the OED
ah, I'm English, not French ;p
it's French. when a fencing opponent gets you with their épée, you admit their success
touché
@Lurvetti i did a golfed version of this, just for fun
@Steffan153 can you beat it? ;)
Awsome, thanks!
Yes.
'b' * True
is'b'
because the integer ofTrue
is 1.And
not 0
isTrue
because the boolean of0
is False, and revert that is True.So, this means that a (variable times True) = (variable) and that (not 0) = (True)?
That's actually pretty clever.
This is great! :D
Loading more items...