#include<stdio.h>
int main()
{
int i = 0;
int count = 0;
int a,b;
for(i=1; i<100; i++)
{
a=i/10;
b=i%10;
if(a/3==3||b/3==3)
{
count++;
}
}
printf("%d",count);
return 0;
}
C語言 1~100 所有整數中出現多少次數字 9
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.