ping is a simple utility, which uses ICMP (Internet Control Messaging Protocol), which is a network layer protocol, and is used to detect and report errors on any computer network, using the TCP/IP or OSI protocol. This protocol ICMP has a mode which enables sending echo messages to a host, primarily in order to determine if a host is up or down. Note that when I say up, I mean it is put on and when I say down, it is turned off.
As described earlier, this ping can be used for any IP or host address. If you see a response
Destination Network Unreachable.
That means you are not connected to any network.
If you see something like
Destination Host Unreachable.
That means, either the host is down, or there is a firewall running on the computer, which is preventing it from responding to your ping request.
If you see something which talks about ttl=something, that means the host is up and is responding to your messages.
The bytes field specifies how many bytes of data was received. The ttl, which happens to be the most cryptic field for newbies is a Time To Live field. Every packet has a ttl field. After passing through that many computers while reaching the destination host, it becomes 0. After it becomes 0, it can no longer propagate. Also note that after it passes through a computer, it is decremented by 1.
Windows OS normally has a ttl 128. Firewalls can however change this. ttl 64 is what we see for most Linux or Unices. However, a ttl of 255 has also been seen in case of Unices.
So, when you see a ttl, you can determine how far the computer is, that is how many hops it travels through. For example, if we have a ttl 49, as in the example given by Girija, we see that adding 15 to the number gives 64, which is a common ttl. So, the packets have probably passes through 15 hops while coming to you.
Note however, that this is the working of the program ping, and what it outputs. It is not the usage of the program ping. However, if you need to know how to use the program, nowhere can be a better place than your computer. Just go to the command line and type
That should display help information. Enough information to tell you how to use the program.