I was trying to figure out how to return a list of ips on my network that are responding to ping. Here’s how you do it with grep, and get a list of just ips:
sudo nmap -sP 192.168.0.100-199 | grep -o 192.[0-9]*.[0-9]*.[0-9]*
Modify “192.168.0.100-199″ for your network’s ip range.