common_network function

Find the common network of two addresses