We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
I did first part like yours, but then when creating the logic I was checking against if's. First it was ugly and then it failed with -10,0,10...
Looking at your approach it very intelligent... getting the max, then deliting all the max's within the list, then looking for a new max.... awesome :D
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Find the Runner-Up Score!
You are viewing a single comment's thread. Return to all comments →
I did first part like yours, but then when creating the logic I was checking against if's. First it was ugly and then it failed with -10,0,10... Looking at your approach it very intelligent... getting the max, then deliting all the max's within the list, then looking for a new max.... awesome :D