HDU2006 求奇數的乘積

#include <iostream> using namespace std; int main() { int n; while(cin >> n) { int result = 1; while(n--) { int x; cin >> x; if(x % 2 == 1) { result *= x; } } cout <<
相關文章
相關標籤/搜索