The friends said goodbye to Matthew Perry