Think of your program as a tree diagram. Once you build your own functions for main to call, you can call them as many times as you want. Enough of this, lets show an example of a function. For one, it takes the number 3 and subtracts one then prints it. Let's take this program line by line.
Functions return a single variable after they are called.
These tell what variable we are giving the function. Also, don't forget your semicolon. Up until now, I had not used void. What this does is says that the function main does not have a return type. You use void for any function that is not returning any variable type.