This c++ code checks whether the given ipv4 is valid or not.
Range for ipv4 is from 0 to 255 for 32 bits divded in 4 parts each of 8 bits.
input - ipv4 address
Output - If valid then print valid ip else print error
Note: implemented without using regex