/* A user-defined function without argument nor result */
#include <stdio.h>/* the function definition */void
stars (void)
{
printf ("********************************\n");
}
/* end of function definition *//* main program */
int
main (void)
{
printf ("The line of stars comes from a function.\n");
/* calling the function */
stars ();
/* the function can be called as will*/
printf ("\n");
stars ();
printf ("Hello world!\n");
stars ();
return (0);
}
The line of stars comes from a function.
********************************
********************************
Hello world!
********************************