28
Marco Punteri
Last seen 4 days ago
Member for 3 years, 1 month, 24 days
Difficulty Advanced
the construction is brilliant but i don't like the coupling, in this code Party has to know the internal implementation of Friend
More
you say your solution is clumsy but it's roman numeration the clumsy one (and i'm italian xD).
I think your solution is neat and more mathematical than mine.
Just on line 50 and 54 you could use the += construct, but it's a peanut.
More
very compact, i like it. Expetially the fight func avoiding the swap between attacker and defender.
More
your rest_life method it would be perfect for an health property, in this way you are not tied to opponent attack
More
in the fight method of battle class is it necessary to duplicate the couple of return? Aren't enough the second ones?
More
ok, yield from is like necromancy for me xD
Out of joke, if i read such a code it's quite obvious to me, but i'm not able to write it from scratch
More
This is because lists are mutable and passed by reference, right?
I like it, despite the classification (imho it's a creative solution, not clear)
More
wow, this is really creative! Never thought that str(array) could work in that way :)
More
i always love to see my solution in just one line, i'm too verbous :)
More
i like the math approach but your seems to be unnecessarily complicated, you coud achieve the same result using the // operator
More
I think this solution is really elegant, even if it's quite puzzling if you don't know how groupby works, expecially for the identity as default keyfunc value!
More
always happy when i see any and all used ;)
More
IMO re is not so readable, but very powerful, and so i don't like so much the "half use" you do
More