Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
75272 sh25_wangtaojie 不定方程求解 C++ 通过 0 MS 240 KB 337 2025-12-05 15:39:09

Tests(1/1):


#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b >> c; int count = 0; for (int x = 0; x <= c / a; x++) { if ((c - a * x) % b == 0) { int y = (c - a * x) / b; if (y >= 0) count++; } } cout << count << endl; return 0; }


测评信息: