fork(1) download
  1. #include <iostream>
  2. #include <vector>
  3. using namespace std;
  4.  
  5. int main() {
  6. vector <double> a;
  7. double b;
  8.  
  9. while (cin >> b){
  10. a.push_back(b);
  11. }
  12. double min=a[0]*a[a.size()/2];
  13. for(int i=0; i<(a.size())/2; i++){
  14. if (a[i]*a[(a.size()/2+i)]< min){
  15. min = a[i]*a[(a.size()/2+i)];
  16. }
  17. }
  18. cout << min;
  19.  
  20. return 0;
  21. }
  22.  
  23.  
Success #stdin #stdout 0s 3464KB
stdin
2 4 8 1 3 5 4 8 1 10 5 2 4 9 3  9 1  5 4 3 7 8 2 11 1 4 5 10 3 8
stdout
4