Heat milk in a pan and bring it to boil add sugar and let it dissolve.
in a bowl add milk, corn flour, rice flour and whisk it well. Add corn flour mixture in boiling milk and whisk it continuously cook until it gets thicken.
In a Pyrex dish spread butter well, and spread the sugar.
Turn on the flame and let the sugar melt in the dish.
Add 2-3 spoon of thicken mixture over the melted sugar and mix it well add the remaining mixture and cook for 4-5 minutes on medium high flame.
Let it cool then keep it in refrigerator for 4-5 hours or overnight.
Garnish it with pistachio.