length:

    1. let arr = [1,2,3]
    2. console.log(arr.length); // 数组的长度为3

    size():

    1. let s = [1,2,3,4]
    2. let arr = new Set(s)
    3. console.log(arr); // Set(4) { 1, 2, 3, 4 }
    4. console.log(arr.size); //对象的长度为4