//       CS210 - Algorithms and Data Structures I
//            Department of Computer Science
//       National University of Ireland, Maynooth
//
//           Solutions to Self-help Exercises
//                     Tom Naughton
//                    November 2000
//
//-------------------------------------------------------
//http://www.cs.may.ie/tnaughton/cs210/cs210selfhelp.html
//=======================================================
class ExerciseI4 {
  /* Prints the larger of two integers
  */
  public static int larger(int a, int b) {
    /* Returns the larger of two ints passed as arguments
    */
    if (a > b) {
      return a;
    } else {
      return b;
    }
  }

  public static void main(String args[]) {
    int a, b;
    a = 5;
    b = 6;
    System.out.print("The larger of " + a + " and ");
    System.out.println(b + " is " + larger(a, b) + '.');
  }
}

