提交时间:2025-12-26 15:32:43

运行 ID: 78257

#include <iostream> #include <vector> using namespace std; int main() { int n; cin >> n; vector<int> numbers(n); int count = 0; for (int i = 0; i < n; i++) { cin >> numbers[i]; int num = numbers[i]; int thousand = num / 1000; int hundred = (num / 100) % 10; int ten = (num / 10) % 10; int unit = num % 10; if (unit - thousand - hundred - ten > 0) { count++; } } cout << count << endl; return 0; }