All datagrams sent by TCP/IP may be received by all machines on a subnetwork. However, normally each host's network adapter ignores any packet that does not specify that computer as its destination. Occasionally, you might want to send a message to all machines on a particular network. To do so, select a broadcast address for your machine. A broadcast address is one in which all bits in the host portion of the IP address have been set to 1 as recommended by RFC 919.
For example, the broadcast address for the class C network address n1.n2.n3.0 would be n1.n2.n3.255. The broadcast address will be different if your network is a subnetted class C network with network and subnet address n1.n2.n3.n4. For example, if the last five bits of the fourth octet are used for the host address, the broadcast address would be n1.n2.n3.n4+(16+8+4+2+1). Thus the network and subnet address 212.158.35.64 with netmask 255.255.255.224 would have a broadcast address of 212.158.35.95.