ensure that have a full array in java
I have an array and I set to this array random values. I want to be to be sure that this array is full (there is a number in each position).How can I ensure about this? I wrote the following code but I’m not sure.

     public boolean check(){
      boolean checks=false;        
      int [] array =new int [10];

      if(array.length==10){
         checks = true;     
      }
    
     return checks;
    }
  
ensure that have a full array in java
===

I have an array and I set to this array random values. I want to be to be sure that this array is full (there is a number in each position).How can I ensure about this? I wrote the following code but I’m not sure.

     public boolean check(){
      boolean checks=false;        
      int [] array =new int [10];

      if(array.length==10){
         checks = true;     
      }
    
     return checks;
    }
  