int []num={2,3,4};用Arrays.asList打印的是哈希值
Integer [] num={2,3,4},打印Arrays.asList就成了集合了 a
import java.util.*;
class ArrarysDemo
{
public static void main(String[] args)
{
int []num={2,3,4};
List li =Arrays.asList(num);
System.out.println(num);
Integer [] nums={2,3,4}
List li =Arrays.asList(nums);
System.out.println(nums);
}
} |
|