A subroutine is the same exact thing as a function.
A subroutine is a collection of markup that can be used in our Pythond script. For example, let's say you want to print a long line of text many times in your script. You can place the long line of text inside of a subroutine.
def myText(): print("This is a very long line of text.") print("This text is going to be used many times.") print("Placing this text over and over in our script is going to make our script look messy.") print("Let's be smart and put the text in a subroutine called myText.")
Since our subroutine is called "myText" in this example, the subroutine can be used simply by placing "myText();" in the Python script.