SOURCE

let ipStr = "128.2.2.2-128.5.67.9";

// 转换成二进制
ipToInt('128.2.2.2')

console.log(13)

function ipToInt(str){
    let arr = str.split('.').map(v => (+v).toString(2));
    console.log(arr);

}
console 命令行工具 X clear

                    
>
console