Public class test 1 {
Public static void main(String[] args){
Scanner sc = new scanner (system. in);
int[]a = new int[ 10];
for(int I = 0; I<a. Length; i++){
System.out.println ("Please enter" +a.length+ "digits, currently"+(I+1)+":);
a[I]= sc . nextint();
}
System.out.print ("array before sorting:");
for(int i:a){
system . out . print(I+" \ t ");
}
system . out . println();
The new test 1 (). f(a);
}
public void f(int[] a){
for(int I = a . length- 1; I>0; I-) {
for(int j = 0; J< me; j++){
if(a[I]& lt; a[j]){
int temp = a[I]; ;
a[I]= a[j];
a[j]= temp;
}
}
}
System.out.print ("sort array:");
for(int i:a){
system . out . print(I+" \ t ");
}
}
}