hey guys, im trying to make a function out of the following code
for(Z=0; Z < 3; Z++)
printf(".");
fflush(stdout);
sleep(1); }
From what i understand, because there is no return value, i need to declare this function i want as void. I want the function to be called periods.
I have used
void periods ()
{
periods()
}
before my main() in an attempt to declare the function
i declare int Z from the for loop right after main()
im returning 0 at the very end.
Currently, the program crashes when it reaches the part where i attempt to create periods(). I have tried without the ; but then i get an debug expectation.
Thanks for the help! Also im a self taught nub so go easy on me!