I am having hard time understanding why the size of ArrayList is zero by default here as opposed to what I have seen on different article that it is actually 10. And even if I change the size, it doesn't get affected.
import java.util.ArrayList;
Class Test{
    private static final ArrayList<Long> foo = new ArrayList<>(1000);
   
    public static void main(String[] args) {
        System.out.println(foo.size());
}
Can anyone explain this?
 
     
    