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.
variable "check" holds the function. and ambda describes the oneliner function.
mult = lambda a,b:a*b
is the same as
def mult(a,b):
return a*b
Try to use tools like debuggex:
https://www.debuggex.com/r/xN8wfXZE1Y4Qd3MO
It shows that your regexp matches two numbers and two any symbols, like this:
"11xx"
point "." match any symbol
may i see your regexp?
Done
fibonacci 1000th time... time to do something funny
This comment is hidden because it contains spoiler information about the solution
it's classic oneliner.
def is ugly, lambda is beautiful in oneliner
zen of python, 1st line:
Beautiful is better than ugly.
No need to write python code.
Its regexp kata, you should edit this regexp string:
Read the wiki!
Every year that is exactly divisible by four is a leap year, except for years that are exactly divisible by 100, but these centurial years are leap years if they are exactly divisible by 400. For example, the years 1700, 1800, and 1900 are not leap years, but the year 2000 is.
Great! That's why i made this kata - you reversed this algorithm better than me!
Great! Approved!
Added this line to the description:
Multiline test cases are unnecessary, i think. The point of kata is to find a way to detect divisibility. It's not about fancy format checking...
Done
The point of this cata is regexp practice and understanding Gregorian calendar.
Loading more items...