#include <stdio.h>
#include <stdlib.h>
int main()
{
int num = 1;
int i = 0;
for (num = 1; num < 101; num++)
{
if (num % 10 == 9)
{
i += 1;
}
if (num / 10 == 9)
{
i += 1;
}
}
printf(“9出现的次数=%d\n”, i);
system(“pause”);
return 0;
}
#include <stdio.h>
#include <stdlib.h>
int main()
{
int num = 1;
int i = 0;
for (num = 1; num < 101; num++)
{
if (num % 10 == 9)
{
i += 1;
}
if (num / 10 == 9)
{
i += 1;
}
}
printf(“9出现的次数=%d\n”, i);
system(“pause”);
return 0;
}