Hi there everyone, still teaching myself c and would like to ask a question.
In my program i'm writing, i use a piece of code an awful lot, namely this construction:
Is it possible to put this into a function that i can call?Code:for (x = 0; x < 9; x++) { for (y = 0; y < 9; y++) { for (z = 0; z < 9; z++) { //Some code here } } }
For example:
I've no idea how i can go about this but would like to know as it would shorten my program by a lot of lines!!!Code:setupcoordinates( Some Code Here );
Thanks everyone for your time.