package project; import java.util.Scanner; public class Assignment6new { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); String[] inputs1 = new String[10000]; String[] inputs2 = new String[10000]; String[] combined1 = new String[20000]; int good1 = 0 ;int good2 = 0 ;int test1 = 0; int test2 = 0; int sorted = 0; int flag1 = 0; int c = 0; int c1 = 0; int c2 = 0; System.out.println("Enter the values for the first array, up to 10000 values, enter 'End' to quit"); while(flag1 == 0) { String orig = scanner.nextLine(); String first = orig.substring(0,1).toUpperCase(); String lowercase = orig.substring(1,orig.length()).toLowerCase(); String test = first + lowercase; if(test.equals("End")) { flag1 = 1; } else { inputs1[c1] = test; combined1[c1] = test; c1++; } } c = 0; System.out.println("Enter the values for the second array, up to 10000 values, enter 'End' to quit"); while(flag1 == 1) { String orig = scanner.nextLine(); String first = orig.substring(0,1).toUpperCase(); String lowercase = orig.substring(1,orig.length()).toLowerCase(); String test = first + lowercase; if(test.equals("End")) { flag1 = 2; } else { inputs2[c] = test; combined1[c+c1] = test; c++; c2++; } } String[] combined2 = new String[c+c1]; for(int i =0; i 1) { i = i-2; } } } for(int i =0; i < (c1+c2);i++) { System.out.print(combined1[i] + " "); } } } }