Choose a container with a thick bottom. Put the milk in it, the sugar, butter and cocoa. Put the container on the stove and stir until the mixture comes to a boil. Set aside 3/4 of the cocoa mixture and leave the remaining 1/4 to cool. Add the yolks of the eggs to the 3/4 mixture and beat well.
Add the flour, finely chopped walnuts, mix well. Separately, beat the egg whites to snow and carefully mix them with the yolks. Pour the mixture into a buttered and floured tray. Put it to bake in moderately heated oven.
Once the finished layer has cooled, smear it with the set aside 1/4 of cream. Optionally, you can cut it into 2 layers and bind the 2 parts with the cream. On top, smear it with cream as well.
Serve the chocolate petits fours cut into small cakes.