Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and beauty - Java one-dimensional array writes a program to read 10 integers from the keyboard and store them in integer array A, and then output the 10 numbers in reverse order.
Java one-dimensional array writes a program to read 10 integers from the keyboard and store them in integer array A, and then output the 10 numbers in reverse order.
Import? Java . util . scanner;

Public? Class? test 1? {

Public? Static electricity Invalid? main(String[]? args)? {

Scanner? sc? =? New? Scanner (system. in);

int? A []? =? New? int? [ 10];

for(int? I = 0; I< 10; i++){

A [me]? =? sc . nextint();

}

for(int? j = a . length- 1; j & gt=0; j -? ){

System.out.print(a[j]+"?" );

}

}

}