38
Awesome Team
Jürgen Strobel
Last seen 23 hours ago
Member for 5 years, 1 month, 12 days
Difficulty Normal
Not bad, and truly O(n). But I could do it in just 2 non nested scans through weights instead of your 3, and in [3 lines of code](https://py.checkio.org/mission/can-balance/publications/juestr/python-3/second-analytical-with-exact-integer-math-only/) :)
More
Nice approach, but IMHO the placement and conditions logic for the return statements is confusing. It would be more clear if they were grouped together in a single if/elif/else cascade at the end of rec_from().
More