Tuesday, 25 February 2014

Program to print IP address

import java.net.InetAddress;
 
class IPAddress
{
   public static void main(String args[]) throws Exception
   {
      System.out.println(InetAddress.getLocalHost());
   }
}

No comments:

Post a Comment