Commit b4c4d18e by stv

Fix Pylint: W0110: (deprecated-lambda)

divide_chemical_expression: map/filter on lambda could be replaced by
comprehension
parent 11020cf1
......@@ -340,11 +340,10 @@ def divide_chemical_expression(s1, s2, ignore_state=False):
return False
if any(
map(
lambda x, y: x / y - treedic['1 factors'][0] / treedic['2 factors'][0],
treedic['1 factors'],
treedic['2 factors'],
)
[
x / y - treedic['1 factors'][0] / treedic['2 factors'][0]
for (x, y) in zip(treedic['1 factors'], treedic['2 factors'])
]
):
# factors are not proportional
return False
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment