Coping array element to another

 public class RotaionArray {

    public static void main(String[] args) {

        

    

    int A[]= {1,2,3,4,5,6,7,8,9,10};

    int B[]=new int[10];

        System.out.print(“B:”);

    for(int i=0;i<A.length;i++){

        B[i]=A[i];

        System.out.print(B[i]+”,”);

      }

            

    }

    

}

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top