79269729

Date: 2024-12-10 20:40:18
Score: 0.5
Natty:
Report link

Another idea is to use the builtin filter function:

>>> d = {'a':1, 'b':2, 'c':3}
>>> dict(filter(lambda x: x[0] != 'c', d.items()))
{'a': 1, 'b': 2}
Reasons:
  • Low length (1):
  • Has code block (-0.5):
Posted by: Chris Flesher