Sunday, 6 March 2016

Simple Java Program to print the IP Address

Java Program to find the IP Address

               The below listed simple Java program can print the IP Address ( Internet Protocol Address) of your Computer. 

Program:


// Java Code to display IP Address on screen

import java.net.InetAddress; 

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

Output:


/192.168.1.103

5 comments :

  1. Those information was very excellent and easily understand all given information,i like that kind of information and it's very helpful at the my studies,thanks for sharing that wonderful opportunity.
    php training in chennai

    ReplyDelete
  2. Another interesting articles and i find more new information,i like that kind of information,not only i like that post all peoples like that post,because of all given information was very excellent.
    ios training in chennai

    ReplyDelete
  3. Superb i got some valuable tips from here. Really its a amazing article i had ever read. I hope it will help a lot for all. Thank you so much for this amazing posts and please keep update like this excellent article.

    Digital Marketing Training Chennai

    ReplyDelete
  4. Wow! wonderful information and easily observed given program coding,it's very helpful in my studies.
    Thanks for sharing that valuable information.
    Oracle SQL Training in Chennai

    ReplyDelete
  5. Really very nice blog information for this one and more technical skills are improve,i like that kind of post.
    Python Training in Chennai

    ReplyDelete