Click here to Skip to main content
15,900,110 members

Comments by Member 12847424 (Top 11 by date)

Member 12847424 16-Jul-17 14:15pm View    
If you are not going to help then why are you even on this site ? Just to write answers like this ?? And you make it look like a big deal. Like you're the smartest person in the world and if you're not going to answer this then the world will stop. This much ego is not good for anybody.
Member 12847424 15-Jul-17 14:11pm View    
Well if you don't wanna answer then just don't write an answer in the first place. Why do you have to write the above anyway ?
Member 12847424 14-Jul-17 22:37pm View    
This is not my homework and I'm not in a school or college. I'm homeschooled.
I was just doing this problem for fun which I found somewhere.
Member 12847424 8-Jan-17 0:21am View    
Yeah ! you're right but I can't think of a way of assigning the index of highest node to all but itself and the ones that are linked to it.
Member 12847424 7-Jan-17 9:29am View    
I've updated my code considering your suggestion of sorting and now my code works fine for 1 <= n <= 10000 in 0.33s of execution time.
But still time limit is exceeding for 1 <= n <= 50000.