I was doing some exercises on codewars and found this question:
Complete the function
scramble(str1, str2)
that returns true if a portion ofstr1
characters can be rearranged to matchstr2
, otherwise returns false.
after completing it and looking at others answers I found:
scramble=lambda a,b,c=__import__('collections').Counter:not c(b)-c(a)
Can someone explain what is happening here? Why is there a =
after the declaration of lambda and how are the arguments being assigned???
I did not found much explanation on this.