Run ID:120459
提交时间:2025-05-25 20:28:25
#include <vector> #include <iostream> using namespace std; int main() { int m; cin >> m; vector<int> rabbits; for(int i = 0; i < m; ++i) { int x; cin >> x; rabbits.push_back(x); } int total_legs = 0; int total_eyes = 0; for(int x : rabbits) { total_legs += x * 4; total_eyes += x * 2; } cout << total_legs << " " << total_eyes << endl; return 0; }