Next time I have a headless Pi on a network without mDNS support (thanks, fellows from the Dark Side networking team 😛 ) this is a way to find the IP it gets:
sudo nmap network/24
on a network with mDNS support (avahi, bonjour…) just
ping raspberrypi.local