IP Address Example Java Program
Definition
An Internet Protocol address (IP address) is a numerical label assigned to each device participating in a computer network that uses the Internet Protocol for communication.IP Address Example Program
import java.net.InetAddress; class FindIPAddress{ public static void main(String args[]) throws Exception{ System.out.println(InetAddress.getLocalHost()); } }
Sample Output
Output is: BM-USER/192.168.0.104
Miscellaneous Programs
- Super Keyword Example Java Program
- This Keyword Example Java Program
- Sleep Function Example Java Program
- IP Address Example Java Program
- Print Date Example Java Program
- Print Time Example Java Program
- Print Week Example Java Program
- User Defined Package Example Java Program
- Command Line Arguments Example Java Program
Read More Articles
- Multiple Inheritance Using Interface Example Java Program
- Single Inheritance Example Java Program
- Multilevel Inheritance Example Java Program
- Hierarchical Inheritance Example Java Program
- Find all Substrings of a given string Example Java Program
- Create Matrix Example Java Program
- Sum Of Three Numbers Example Java Program
- Twin Prime Example Java Program
- Heap Sort Example Java Program
- Compile Time Polymorphism Example Java Program