HOW DO I CONVERT A NUMERIC IP ADDRESS LIKE 192.18.97.39 INTO A HOSTNAME LIKE JAVA.SUN.COM?

Mayank Tripathi

Total Post:807

Points:4035
Posted by  Mayank Tripathi
Java 
 743  View(s)
Ratings:
Rate this:
  1. Mayank Tripathi

    Post:807

    Points:4035
    How do I convert a numeric IP address like 192.18.97.39 into a hostname like java.sun.com?

    By InetAddress.getByName("192.18.97.39").getHostName() where 192.18.97.39 is the IP address.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!