I would probably immediately respond with a sequence of prime numbers on repeat...
Sort of a 'Please hold' signal to keep them looking as a longer response was drawn up....
The format of the signal would likely dictate the format of the response...
Were you thinking radio waves? Or my personal favorite- Laser Communication? Or something more exotic?
If LIGO detects a gravity wave signal of artificial origin, or Super-Kamiokande detects communication pulses of neutrinos then we can just listen- we don't have the technology to respond in kind, or even precisely identify the exact origin of the signal.
