'When to use “ extends” in azure pipeline

I am getting confused when to use”extends” in the azure pipeline and can I refer templates directly with out extends as well?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source