get firs IP and last IP of a network: how?

get firs IP and last IP of a network: how?

am 21.06.2006 20:13:53 von _mario lat

hallo,
I'd like to know the first ip, mask and last ip of a network.
BUT I know only an IP and network:
for example:

192.168.134.197/30

where 192.168.134.197 is not a network but an ip of a network.

for this reason the follow command don't works:

my $ip = new Net::IP ('192.168.134.197/30') or die (Net::IP::Error());

How can I do?
Thank you in advance,
Mario.