[JAVA beginner] encountered a problem with guide package error

recently learned about the collection framework, doing book examples. The
code is as follows:

import java.util.ArrayList;
import java.util.List;
import java.util.Arrays;

public class Test {
    public static void main(String[] args) {
        ArrayList list = new ArrayList();
        list.add("");
        list.add("");
        list.add("");

        System.out.println(list.contains(""));

        list.remove(0);
        System.out.println("----------------------------");
        list.set(1,"");

        for(int i=0; i<list.size(); iPP) {
            String name = (String)list.get(i);
            System.out.println(name);
        }

        System.out.println("-----------------------------");

        System.out.println(list.indexOf(""));

        list.clear();

        System.out.println("-----------------------------");

        for(Object obj:list) {
            String name = (String)obj;
            System.out.println(name);
        }

        System.out.println(list.isEmpty());

    }
}

Code compilation result:

clipboard.png

---------------------------------------------



:

clipboard.png

:


:

clipboard.png


*Arrays

----------------------2-----------------------

printenv:


----------------------3-----------------------

unset CLASSPATH:

clipboard.png

Jul.08,2021

suspects that you misconfigured the CLASSPATH environment variable. Post the printenv output to see

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3aa00-2c213.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3aa00-2c213.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?