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.
This is nicely structured but I would change the variable name from ret to something more meaningful
This is clever indeed but also makes the code too vague
Comprehensions are used very commonly in real-life scenarios. It's even in the google style guide to use them when the expressions are not overly complicated.
Lambda function are a different story, though. While lambdas are commonly used for simple functions, you wouldn't normally use them as many of the solutions do here. Creating a lambda function and then assigning it to a variable sort of defeats the purpose of a lambda function unless you're using it to nest functions, and even then you'd only do that for very simple functions. However, most people on codewars just use them to reduce the number of lines in their code.
This is actually clever, well done!
here are few examples to simplify it:
map(int, a) --> apply int to every list object in list a to make them integers
map(str, a) --> apply str to every list object in list a to make them strings
Its nice to see this type of solution where the its "opened up" with empty list and normal for loop. There's a lot of solutions with lambda and comprehension (one liners) but these dont add that much value to real life scenarios when the talking point is maintanability. :)