BlueToadGaming BlueToadGaming
  • 06-12-2021
  • Computers and Technology
contestada

I need an If else statement that sorts three numbers from a file from least to greatest

Respuesta :

Talanat
Talanat Talanat
  • 06-12-2021
void sort3(int& a, int& b, int& c)
{
if (a > b)
{
std::swap(a, b);
}
if (b > c)
{
std::swap(b, c);
}
if (a > b)
{
std::swap(a, b);
}
}
Answer Link

Otras preguntas

What is the primary source of Jupiter’s internal heat?
Which health resource is most appropriate for a woman who thinks she might be pregnant? an emergency room a nurse practitioner a pediatrician
Which term describes the process whereby toxic substances increase along trophic levels of an ecosystem? biomassification biomagnification bioentropy heterotrop
I'll give out brainliest. Help me answer the question.
which of the following statements correctly in the case of the two triangles and figure out congruent?​
What are the major differences between the male pelvis and female pelvis that permit childbirth in females?
A 75.0 kg students sits 1.15 m away from a 68.4 kg student. What is the force of gravitational attraction between them? Give answer in scientific notation.
What was the solar nebula like? Why did the Sun form at its center?
Prepare a algorithm visualization for the Tower of Hanoi when 4 disks are to be moved from spindle #1 to spindle #3.
You dispense a quantity of 180 tablets for a prescription written for Ibuprofen 800mg to be taken by mouth 3 times a day. How many days will the prescription la
good job