16 lines
220 B
C
16 lines
220 B
C
|
#include <stdio.h>
|
||
|
void counter()
|
||
|
{
|
||
|
static int i = 0;
|
||
|
i++;
|
||
|
printf("I was called %d times.\n", i);
|
||
|
}
|
||
|
|
||
|
int main(int argc, const char *argv[])
|
||
|
{
|
||
|
for (int x = 0; x < 20; x++)
|
||
|
{
|
||
|
counter();
|
||
|
}
|
||
|
}
|