#include <bits/stdc++.h>
using namespace std;
 
#define ll long long
#define ull unsigned long long
#define ld long double
 
void Free_palestine() {
    ios::sync_with_stdio(false);
    cin.tie(NULL);
    cout.tie(NULL);
}
 
const int N = 2e5 + 5;
const int MOD = 1e9 + 7;
const int MAXN = 1005;
int a[MAXN];
 
signed main(){
  Free_palestine();
  int n;
  cin>>n;
  
  for (int i = 1; i <= n; i++) {
        cin >> a[i];
    }

    int val = a[1];
    int pos = 1;

    for (int i = 2; i <= n; i++) {
        if (a[i] < val) { 
            val = a[i];
            pos = i;
        }
    }

    cout <<val << " " <<pos << "\n";

    return 0;
}