Is there a way to retrieve an entities pitch and yaw via commands in text form?

Hi, I need to retrieve the pitch and yaw of a specific player in the chat
Continue to help post