To solve this problem, we'll take 3 different approaches.
Enjoy the video ππ
Also written version https://losseff.xyz/katas/016-count-of-positives-sum-of-negatives/javascript/
To solve this problem, we'll take 3 different approaches.
Enjoy the video ππ
Also written version https://losseff.xyz/katas/016-count-of-positives-sum-of-negatives/javascript/
For further actions, you may consider blocking this person and/or reporting abuse
Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.
sharathchandark -
Georgios Kampitakis -
sharathchandark -
sharathchandark -
Top comments (2)
With only a reduce:
EDITED: now should work
I like your approachπ Thanks for sharing itπ
I though about reduce, but for some reasons didn't give it a shot.
But this solution won't pass the tests. It'll always return [0, 0]
I assume you made a few typos, it happens to me all the time))
I'd change it like this:
I think it might look like this.