If the destination address belongs to your friend, then the solution is to ask your friend to send it back and hope that your friend is a good friend, so that your money will be returned.
But if the destination address is one you don't recognize, then this is quite fatal. As long as the cryptocurrency transaction cannot be cancelled, you will lose the money as long as you send cryptocurrency to an address whose private key you do not know.
Therefore, every time you send a cryptocurrency balance, you always double-check the destination address.