Wirte a function that find the n biggest element from the list .Put these elements in an array in descending order . (You can run the list only once) .
I am a beginner , can someone guide me to solve this problem ? I haven't understood list really well .
n is a number for example i have this list 1 2 30 5 7 and find the 3 biggest elements (so n=3) and write to an array (You can run the list only once)
It's a linear list .
I need this because if i do not submit to my teacher , i'll not be able to participate in final exam :( so please if you know and it's easy for you please help me ! I really need your help , thank you ! :)