Input output smart contract for NFT sale

Hi everyone I am new here and I came for the knowledge. I want to know if it is feasible to receive the funds of a NFT sale in one ETH address that will split the total amount and send it automatically to five different eth addresses. Also I would like to be pointed in the direction I should look for please.

Would it be possible to code this but I would not know the secret keys of the receiving address? It is for a partnership between 5 people and we need it to be trustless. Multi-sig would resolve this?

Thank you all!