Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
They're not.
{'pos': [3, 7], 'peak': [6, 3]} should equal {'pos': [3, 7], 'peaks': [6, 3]}
{'pos': [3, 7], 'peak': [6, 3]} should equal {'pos': [3, 7], 'peaks': [6, 3]}
{'pos': [3, 7, 10], 'peak': [6, 3, 2]} should equal {'pos': [3, 7, 10], 'peaks': [6, 3, 2]}
TF is this? These are completely SAME (pls help)
Finding thepeaks is not difficult, but your wanted solution with a Map and List is confusing, why not use a Map and put a position and a peakheight together?
https://www.codewars.com/kata/5279f6fe5ab7f447890006a7/discuss#64f5b8c72b610bbbb906767f
What is "peaks"??????????????????????
why for [3,2,3,6,4,1,2,3,2,1,2,2,2,1] the result is [3, 7, 10] why doenst [3, 7, 10, 12]
After a few hours, I still don't understand what I did, but it works
Thank you, finally an explanation
Glad I unlocked the solutions instead of wasting time on this crap..
The correct result for your example is
Scala translation
damn, maybe I'm bad, but for me, reading discussions is much more interesting than reading books or watching TV shows, hopes are crumbling right before our eyes and destinies are changing)
//This implementation iterates through the array, identifies plateaus, and checks for peaks. The positions and values of peaks are stored in the result object, and the final result is returned
Don't make me beg you like my brawl stars account was stolen
peace
Loading more items...