- 8 9 Lab Max And Min Numbers Write A Program Whose Inputs Are Four Integers And Whose Outputs Are The Maximum And The M 1 (63.39 KiB) Viewed 61 times
8.9 LAB: Max and min numbers Write a program whose inputs are four integers, and whose outputs are the maximum and the m
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am
8.9 LAB: Max and min numbers Write a program whose inputs are four integers, and whose outputs are the maximum and the m
8.9 LAB: Max and min numbers Write a program whose inputs are four integers, and whose outputs are the maximum and the minimum of the four values. Ex: If the input is: 12 18 4 9 the output is: Maximum is 18 Minimum is 4 The program must define and call the following two methods. Define a method named maxNumber that takes four integer parameters and returns an integer representing the maximum of the four integers. Define a method named minNumber that takes four integer parameters and returns an integer representing the minimum of the four integers. public static int maxNumber(int numi, int num2, int num3, int num4) public static int minNumber(int numi, int num2, int num3, int num4) 367608.2443884.qx3zqy7 LAB ACTIVITY 8.9.1: LAB: Max and min numbers 0/10 LabProgram.java Load default template... 1 import java.util.Scanner; 2 3 public class LabProgram { 4 5 /* Define your method here */ 6 7 public static void main(String[] args) { 8 /* Type your code here. */ 9 } 10} 11