import java.util.Scanner; public class Solution { public static void main(String[] args) { Scanner input = new Scanner(System.in); int[] number = new int[10]; System.out.print("Enter 10 numbers: "); for(int i = 0; i < 10; i++) number[i] = input.nextInt(); input.close(); for(int i = 0; i < 9; i++) { for(int j = i + 1; j < 10; j++) System.out.println(number[i] + " " + number[j]); } } }