I want to know the host name and provider name for tcs web
mail
Answers were Sorted based on User's Feedback
Answer / deepak divvela
String hostname=Inetaddress.getAddress("portno of tcs
mail").getHostName();
| Is This Answer Correct ? | 8 Yes | 2 No |
Answer / abhilash
String hostname= InetAddress.getByName("portno of tcs
mail").getHostName();
| Is This Answer Correct ? | 4 Yes | 3 No |
Answer / ajay agarwal
String hostname=Inetaddress.getAddress("portno of tcs
mail").getHostName();
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / shaik baji
import java.net.*;
class GetIPAddress
{
public static void main(String[] args) throws
Exception
{
InetAddress obj = InetAddress.getLocalHost
();
String ipAddress=obj.getHostAddress();
System.out.println(ipAddress);
}
}
| Is This Answer Correct ? | 1 Yes | 1 No |
Answer / ss
String ipAddress=InetAddress.getByName
("www.tcs.com").getHostAddress();
| Is This Answer Correct ? | 0 Yes | 2 No |
What is the purpose of using javap?
What do you understand by soft reference?
Is string is a data type?
What is multithreading ???? How to stop multithrading in java????
What is the difference between JVM and JRE?
How does indexof work?
How many decimal places is a double?
Can java hashmap have duplicate keys?
what is difference between requestprocessor and request dispatcher?
please tell me what is wrapper class in java with example ?
What are the features in java?
What is the relationship between clipping and repainting under awt?