At the moment the Bitcoin protocol limits the number of M and N to 15. These are generally written as M-of-N transactions where N is the total number of keys and M are the number of signatures required to unlock the transaction and spend it.
These transactions are very useful for businesses where two are needed to sign off on a particular transaction or even as a joint account where the format between a couple would be set as 1-of-2 – or where either of the couple can use the funds.
If a 2-of-3 multisignature condition is set – then any two key signature combinations of the three keys can unlock the funds. The Locking and Unlocking scripts are shown below:
=2 3 OP_CHECKMULTISIG = or any permutation of Sig1,2,3
When this is executed the result, if the conditions is met, is equal to one and the transaction is verified and will be propagated throughout the Bitcoin network.