A community for students.
Here's the question you clicked on:
 0 viewing
anonymous
 5 years ago
algorithm to find smallest two numbers from list
anonymous
 5 years ago
algorithm to find smallest two numbers from list

This Question is Closed

anonymous
 5 years ago
Best ResponseYou've already chosen the best response.0how many no.s are given??

anonymous
 5 years ago
Best ResponseYou've already chosen the best response.0its a sequence of numbers from 1 to n distinct

anonymous
 5 years ago
Best ResponseYou've already chosen the best response.0use an array to store this numbers. compare the first element of the array with the rest. if any no becomes smaller than the first no. while checking then replace the first no with the smaller one and continue the checking the the new no. at last you will get the smallest no. at the first position.

anonymous
 5 years ago
Best ResponseYou've already chosen the best response.0write algo that returns index of the first item that is less than its predecessor in sequence S1 ............. Sn, if s in nondecreasing order that algo returns the value 0

anonymous
 5 years ago
Best ResponseYou've already chosen the best response.0do u know C language?

anonymous
 5 years ago
Best ResponseYou've already chosen the best response.0take c as a array. c={1st , 2nd,........nth} for (i=0:1<n:i++) { if (c(0)<=c(i)) c(0)=c(i); } printf("\n %f ",c(0));
Ask your own question
Sign UpFind more explanations on OpenStudy
Your question is ready. Sign up for free to start getting answers.
spraguer
(Moderator)
5
→ View Detailed Profile
is replying to Can someone tell me what button the professor is hitting...
23
 Teamwork 19 Teammate
 Problem Solving 19 Hero
 Engagement 19 Mad Hatter
 You have blocked this person.
 ✔ You're a fan Checking fan status...
Thanks for being so helpful in mathematics. If you are getting quality help, make sure you spread the word about OpenStudy.