Pre-cook the tapioca pearls and the rice in boiling water for 2 minutes. Drain. Place them in another pot and cover with coconut milk, add sugar and bring to the boil. Reduce heat and simmer until tapioca and rice are tender.
Don't forget to stir from time to time.
Depending on the type of rice, cooking time may vary from 20 minutes to a couple of hours. The longer the time, the more liquid you will have to add.
Remove from heat and add in the egg yolk, butter and whatever other ingredient(s) you like. Sometimes I use grated skin of citrus - you can choose the one you prefer or a combination of several. I also use herbs like mint, basil, etc... In this last case, I add the herbs at the beginning, in a metal tea bag infuser.
But my favorite flavour is with orange blossom flowers. So damn good...
Let in cool down. Refrigerate for few hours. I love when the rice pudding is very cold.