Answer:
import java.util.Scanner;
public class App {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int high = 0;
int low = 0;
for (int i = 0; i < 15; i++) {
System.out.print("Enter a number: ");
int num = scanner.nextInt();
if (i == 0) {
high = num;
low = num;
}
if (num > high) {
high = num;
}
if (num < low) {
low = num;
}
}
System.out.println("Highest number is: " + high);
System.out.println("Lowest number is: " + low);
}
}
Explanation:
Output Console