Start by bringing all the ingredients to room temperature if they were refrigerated. It's best to keep the refrigerated ingredients on the counter 30 minutes prior to baking.
Preheat the oven to 400 °F (200 °C). Grease a 6 inch round pan with butter or line it with parchment paper. I used baking spray which worked great.
Sift together all purpose flour, baking soda and baking powder 2-3 times.
In a large mixing bowl, beat the sugar, yogurt, milk and olive oil for 5 minutes on high speed till sugar dissolves. This step is important as beating the mixture will aerate it well and you will get a perfect cake with great crumbs.
If you are not using a stand mixer, use a hand mixer to whisk the ingredients. Beating it with hands using a wire whisk is also an option but it will require lot of arm strength.
Add in cinnamon powder and vanilla extract and give a quick stir. Keep scraping the sides of the bowl.
Slowly fold in grated carrots gently. You do not want to disturb the air that you have incorporated in earlier steps.
Now add the flour in 2 lots, mixing well after each addition. Keep scraping the sides of the bowl.
You can add chopped walnuts in the batter as well if you wish. It is optional.
Pour the batter in the prepared pan. Top with chopped walnuts. Bake at 400 °F (200 °C) for 10 minutes, reduce temperature to 170 °C and bake for 20-25 minutes or till a toothpick inserted into the cake comes out clean.
If the cake is getting browned from the top too soon, cover it using a piece of aluminum foil. Remove the pan from the oven and let the cake rest for 10 minutes in the pan.
Cool the cake for 30 minutes and then overturn onto a plate. Wait for at least 2 hours before slicing it for neat slices.