//数组二相对于数组一所新增的数据
function add_msg(a,b){
    return a.filter(function(i){
        return b.indexOf(i) === -1
    })
}

//数组二相对于数组一所删除的数据
function delete_msg(a,b){
    return b.filter(function(i){
        return a.indexOf(i) === -1
    })
}

  

相关文章: