c++ ip subnet generator