How to simplify & optimize Merkle trees construction & verification within tapscript?? Use of 'OP_CAT'.
Pops the top 2 values off the stack, concatenates the popped values together & pushes the concatenated value onto the top of the stack but fails if there are fewer than 2 values on the stack & the concatenated value exceeds the max script element size of 520 Bytes.
By concatenating pub keys using the 'OP_CAT' opcode, Bitcoiners can create advanced multisignature addresses, enhancing security & enabling more complex transaction schemes on the Bitcoin network….
https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2023-October/022049.html