Finding the Maximum of Two Doubles
Here’s a small function that you might write to find the maximum of two double numbers.
int maximum(double a, double b)
{
if (a > b)
return a;
else
return b;
}
Previous slide
Next slide
Back to first slide
View graphic version