2 条题解
- 1
信息
- ID
- 134
- 时间
- 1000ms
- 内存
- 256MiB
- 难度
- 10
- 标签
- 递交数
- 5
- 已通过
- 4
- 上传者
#include <stdio.h>
int main()
{
int x,y=0;
int a,b,c=0;
int count=0;
scanf("%d %d %d",&a,&b,&c);
for (x=0;x<=1000;x++){
for (y=0;y<=1000;y++){
if (a*x+b*y==c)
count++;
}
}
printf("%d",count);
return 0;
}