Write the definition of a method max that has three int parameters and returns the largest.

Write the definition of a method max that has three int parameters and returns the largest.

LANGUAGE: JAVA

CHALLENGE:

Write the definition of a method max that has three int parameters and returns the largest.

SOLUTION:


public int max (int aint, int bint, int cint){
   return Math.max(aint, Math.max(bint, cint));
}

Add comment