Calculating a subnet mask depends on whether you are using the default, classful mask or a true subnet mask to divide a network into smaller pieces.
The defaults are on octet boundaries (every 8 bits):
255.0.0.0 class A network
255.255.0.0 class B network
255.255.255.0 class C network
Any other type of subnet mask with 4 octets (iPV4) can use combinations of those with any octet value from 0 - 255. No number may be larger than 255.
Calculating other subnet masks would be based on how many subnets you want in the network. You could have values such as:
255.192.0.0
255.255.248.0.0
255.255.255.252
The first octet must at least be 255. The other octets may change, based on whether it is a classful default network or it is being subnetted.
The correct term is subnet mask instead of subnet mass. A subnet mask separates an IP address into the host address and the network address. It is a 32-bit number that can mask an IP address.
This is a network address
The network address of an IPv4 address of 192.168.7.5 with a subnet mask of 255.255.255.0 would be 192.168.7.0. Remember that the subnet mask determines the network portion of the IP Address.
255.255.255.0
255.255.255.0
it is a class c address..so default subnet mask is 255.255.255.0 it is a private address...
The default subnet mask for this address - a class A address - is 255.0.0.0 (same as /8).
Subnet mask for the above is 255.0.0.0
The default subnet mask would be 255.255.0.0 for a class B address.
if the ip address is 192.168.2.1 then the subnet mask should be 255.255.255.0
There isn't just a single subnet mask that could be used for that address. The default subnet mask would be 255.0.0.0, but there could be others if the network is subnetted.
Example IP address of 192.168.1.123 with a subnet mask of 255.255.255.0