+ 2
Why the filter function does not work as I expect?
In the toreplace variable, I would expect [3, 7] https://code.sololearn.com/cL8j8MfU0VyL/?ref=app
4 Respuestas
0
Thanks, should not it work with any kind of iterables? Only with lists?
0
Tamás Berki I think map and filter should work for all builtin iterables, but I'll check whether there are any exceptions.
0
Try removing the first 2 print statements or swapping the last 2 print statements, very confusing, I can't explain this.