import java.net.MalformedURLException;
import java.net.URL;
import java.util.logging.Logger;

public class Test{

    public static void main(String [] args) throws MalformedURLException{
        final Logger logger = Logger.getLogger(Test.class.getName());
        String address = "https://www.google.com/";
        
        URL firstUrl = new URL(address);
        URL secondUrl = new URL(address);

        logger.info(Boolean.toString(firstUrl.equals(secondUrl))); // prints false
    }
}

