fork download
  1. #include<bits/stdc++.h>
  2.  
  3. using namespace std;
  4.  
  5. int n, a[1003];
  6.  
  7. int main(){
  8. cin >> n;
  9. for(int i = 1; i <= n; i++){
  10. cin >> a[i];
  11. }
  12. int MIN = 100000000;
  13. for(int i = 1; i <= n; i++){
  14. MIN = min(MIN, a[i]);
  15. }
  16.  
  17. cout << MIN;
  18. }
  19.  
Success #stdin #stdout 0.01s 5288KB
stdin
Standard input is empty
stdout
100000000