Ok, here is the problem.

I am having issues with creating functions within my code.

What sort of issues are these?
That code compiles.