Here's what I recieve: enter image description here

Here is my complete code:

import java.net.*;
import java.io.*;
class whois {
  public static void main(String args[])throws Exception {
     int c;
     Socket s=new Socket("whois.internic.net",43);
     InputStream in=s.getInputStream();
     OutputStream out=s.getOutputStream();
     String str=(args.length==0 ? "www.osborne.com" : args[0])+"\n";
     byte buf[]=str.getBytes();
     out.write(buf);
     while((c=in.read())!=-1) {
       System.out.print((char)c);
     }
     s.close();
  }
}

If Time passes to this and kind there osborne.com, they'll produce details about this domain. But I get another output. What's the reason behind this? Please explain.

Improve your "www.osborne.com" to "osborne.com".

osborne.com is really a registered domain which you'll look for in whois. www.osborne.com is really a host, not really a domain.

You're typing osborne.com in to the whois page, however in your code you're using www.osborne.com. Improve your code to make use of osborne.com rather than www.osborne.com.