code: func DiffAddr(newConfig []*net.IPNet, oldConfig []*net.IPNet) (toBeDeleted []*net.IPNet, toBeAdded []*net.IPNet) {
  	var add []*net.IPNet
  	var del []*net.IPNet
  	//sort
  	n := SortedIPs(newConfig)
  	sort.Sort(&n)
  	o := SortedIPs(oldConfig)
  	sort.Sort(&o)
  
  	//compare
  	i := 0
  	j := 0
  	for i < len(n) && j < len(o) {
  		if eqAddr(n[i], o[j]) {
  			i++
  			j++
  		} else {
  			if lessAdrr(n[i], o[j]) {
  				add = append(add, n[i])
  				i++
  			} else {
  				del = append(del, o[j])
  				j++
  			}
  		}
  	}
  
  	for ; i < len(n); i++ {
  		add = append(add, n[i])
  	}
  
  	for ; j < len(o); j++ {
  		del = append(del, o[j])
  	}
  	return del, add
  }
docs: // DiffAddr calculates the difference between two slices of AddrWithPrefix configuration.
  // Returns a list of addresses that should be deleted and added to the current configuration to match newConfig.