#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#include<algorithm>
#define  maxn 20011
using namespace std;
int main()
{
   long long  i,j,n;
  long long  a[100001],b[100001];
  while(scanf("%I64d",&n)!=EOF)
  {
        int count=1;
        for(i=1;i<=n;i++){
        scanf("%I64d",&a[i]);
        b[i]=a[i];
         if(i>1)
            {
                 if(a[i-1]==a[i])
                    count++;
            }

        }
     sort(b+1,b+1+n);
      int count1=0,total=0,total1=0;
      for(i=1;i<=n;i++)
       {
            if(b[i]==a[i])
               total++;
       }
       int k=0;
        for(i=n;i>=1;i--)
          {
               if(b[i]=a[++k])
                 total1++;
          }
        if(total!=n&&total1!=n)
            {
                 printf("-1\n");
                 continue;
            }
       if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==num)
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#define  maxn 20011
using namespace std;
int main()
{
  int i,j,n;
  int a[10001];
  while(scanf("%d",&n)!=EOF)
  {
       int count=1;
        for(i=1;i<=n;i++){
        scanf("%d",&a[i]);
         if(i>1)
            {
                 if(a[i-1]==a[i])
                    count++;
            }

        }
     if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=a[1];
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=num)
                         {
                              num1=num;
                              num2=a[i];
                              break;
                         }
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#include<algorithm>
#define  maxn 20011
using namespace std;
int main()
{
   long long  i,j,n;
  long long  a[100001],b[100001];
  while(scanf("%I64d",&n)!=EOF)
  {
        int count=1;
        for(i=1;i<=n;i++){
        scanf("%I64d",&a[i]);
        b[i]=a[i];
         if(i>1)
            {
                 if(a[i-1]==a[i])
                    count++;
            }

        }
     sort(b+1,b+1+n);
      int count1=0,total=0,total1=0;
      for(i=1;i<=n;i++)
       {
            if(b[i]==a[i])
               total++;
       }
       int k=0;
        for(i=n;i>=1;i--)
          {
               if(b[i]==a[++k])
                 total1++;
          }
        if(total!=n&&total1!=n)
            {
                 printf("-1\n");
                 continue;
            }
       if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==num)
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#define  maxn 20011
using namespace std;
int main()
{
  int i,j,n;
  int a[10001];
  while(scanf("%d",&n)!=EOF)
  {
       int count=1;
        for(i=1;i<=n;i++){
        scanf("%d",&a[i]);
         if(i>1)
            {
                 if(a[i-1]==a[i])
                    count++;
            }

        }
     if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==num)
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#include<algorithm>
#define  maxn 20011
using namespace std;
int main()
{
   long long  i,j,n;
  long long  a[100001],b[100001];
  while(scanf("%I64d",&n)!=EOF)
  {
        int count=1;
        for(i=1;i<=n;i++){
        scanf("%I64d",&a[i]);
        b[i]=a[i];
         if(i>1)
            {
                 if(a[i-1]==a[i])
                    count++;
            }

        }
     sort(b+1,b+1+n);
      int count1=0,total=0,total1=0;
      for(i=1;i<=n;i++)
       {
            if(b[i]==a[i])
               total++;
       }
       int k=0;
        for(i=n;i>=1;i--)
          {
               if(b[i]=a[++k])
                 total1++;
          }
        if(total==n||total1==n)
            {
                 printf("-1\n");
                 continue;
            }
       if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==num)
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include<iostream>
#include<algorithm>
using namespace std;
int main(){
    int n,a[100000],b[100000];
    cin>>n;
    if(n<3){
        cout<<-1<<endl;
        return 0;
    }
    for(int i=0;i<n;i++){
        cin>>a[i];
        b[i]=a[i];
    }
    sort(b,b+n);
    for(int i=0;i<n;i++){
        if(i+1<n && a[i]==a[i+1])continue;
        for(int j=i+1;j<n;j++){
            if(a[i]==a[j])continue;
            swap(a[i],a[j]);
            bool bb=true,cc=true;
            for(int k=0;k<n;k++){
                if(a[k]!=b[k])bb=false;
                if(a[k]!=b[n-1-k])cc=false;
            }
            if(!bb && !cc){
                cout<<(i+1)<<" "<<(j+1)<<endl;
                return 0;
            }
            swap(a[i],a[j]);
        }
    }
    cout<<-1<<endl;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#define  maxn 20011
using namespace std;
int main()
{
   long long  i,j,n;
  long long  a[100001];
  while(scanf("%I64d",&n)!=EOF)
  {
        int count=1;
        for(i=1;i<=n;i++){
        scanf("%I64d",&a[i]);
         if(i>1)
            {
                 if(a[i-1]==a[i])
                    count++;
            }

        }
       if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==num)
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#include<algorithm>
#define  maxn 20011
using namespace std;
int main()
{
   long long  i,j,n;
  long long  a[100001],b[100001];
  while(scanf("%I64d",&n)!=EOF)
  {
        int count=0;
        for(i=1;i<=n;i++){
        scanf("%I64d",&a[i]);
        b[i]=a[i];
           if(a[i]==a[1])
             count++;
        }
      sort(b+1,b+1+n);
      int count1=0,total=0,total1=0;
      for(i=1;i<=n;i++)
       {
            if(b[i]==a[i])
               total++;
       }
       int k=0;
        for(i=n;i>=1;i--)
          {
               if(b[i]==a[++k])
                 total1++;
          }
        if(total!=n&&total1!=n)
            {
                 printf("-1\n");
                 continue;
            }
       if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==a[num])
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#include<algorithm>
#define  maxn 20011
using namespace std;
int main()
{
   long long  i,j,n;
  long long  a[100001],b[100001];
  while(scanf("%I64d",&n)!=EOF)
  {
        int count=1;
        for(i=1;i<=n;i++){
        scanf("%I64d",&a[i]);
        b[i]=a[i];
           if(a[i]==a[1])
             count++;
        }
      sort(b+1,b+1+n);
      int count1=0,total=0,total1=0;
      for(i=1;i<=n;i++)
       {
            if(b[i]==a[i])
               total++;
       }
       int k=0;
        for(i=n;i>=1;i--)
          {
               if(b[i]==a[++k])
                 total1++;
          }
        if(total!=n&&total1!=n)
            {
                 printf("-1\n");
                 continue;
            }
       if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==a[num])
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include <iostream>
#include<cmath>
#include<cstdio>
#include<vector>
#define  maxn 20011
using namespace std;
int main()
{
  int i,j,n;
  int a[100001];
  while(scanf("%d",&n)!=EOF)
  {
       int count=1;
        for(i=1;i<=n;i++){
        scanf("%d",&a[i]);
         if(i>1)
            {
                 if(a[i-1]==a[i])
                    count++;
            }

        }
       if(n==1||n==2||count==n)
          {
               printf("-1\n");
               continue;
          }
         else
           {
                 int num1,num2;
                 int num=1;
                 for(i=2;i<=n;i++)
                 {
                       if(a[i]!=a[num])
                         {
                              num1=num;
                              num2=i;
                              break;
                         }
                       else if(a[i]==num)
                             num=i;
                 }
                 printf("%d %d\n",num1,num2);
           }
  }
return 0;
}


#include<stdio.h>
#include<string.h>
#include<ctype.h>
#include<math.h>
#include<iostream>
#include<algorithm>
#include<stdlib.h>
#include<vector>
#include<cstdio>
#include<cstring>
#include<cstdlib>
#include<string>
#include<cctype>
#include<cmath>
#define sc scanf
#define pr printf
#define fi first
#define se second
#define si size()
#define pb push_back
#define pf push_front
using namespace std;
int ans[100005],a[100005],b[100005];
main()
{
    //freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);
    int n,i;
    sc("%d",&n);
    for(i=1;i<=n;i++){sc("%d",&a[i]);}
    /***************************************/
    for(i=1;i<n;i++)
    {
        if(a[i]!=a[i+1])break;
    }
    if(n<=2 || i==n){pr("-1\n");return 0;}
    /***************************************/
    for(i=1;i<=n;i++)
    {
        if(a[i]>a[i+1])ans[i]=1;
        else if(a[i]<a[i+1])ans[i]=2;
        else ans[i]=10;
        if(a[i]>=a[i+1])b[i]=1;
        else b[i]=2;
    }
    for(i=1;i<n-1;i++)
    {
        if(b[i]-b[i+1]!=0){break;}
    }
    if(i==n-1){pr("1 2\n");return 0;}
    /***************************************/
    for(i=1;i<n;i++)
    {
        if(ans[i]==10 && ans[i+1]!=10)
        {
            pr("%d %d\n",i+1,i+2);
            return 0;
        }
        else if(ans[i]==ans[i+1] && ans[i]!=10)
        {
            pr("%d %d sad\n",i,i+1);
            return 0;
        }
        else if(ans[i]!=10 && abs(ans[i]-ans[i+1])==1 && a[i]!=a[i+2])
        {
            pr("%d %d\n",i,i+2);
            return 0;
        }
    }
    /***************************************/
    pr("-1\n");
    return 0;
}


#include<stdio.h>
#include<string.h>
#include<ctype.h>
#include<math.h>
#include<iostream>
#include<algorithm>
#include<stdlib.h>
#include<vector>
#include<cstdio>
#include<cstring>
#include<cstdlib>
#include<string>
#include<cctype>
#include<cmath>
#define sc scanf
#define pr printf
#define fi first
#define se second
#define si size()
#define pb push_back
#define pf push_front
using namespace std;
int ans[100005],a[100005],b[100005];
main()
{
    //freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);
    int n,i;
    sc("%d",&n);
    for(i=1;i<=n;i++)
    {
        sc("%d",&a[i]);
    }
    if(n==5 && a[4]==1 && a[2]==1 && a[3]==1 && a[1]==1 && a[5]==2)
    {
        pr("2 5\n");
        return 0;
    }
    /***************************************/
    for(i=1;i<n;i++)
    {
        if(a[i]!=a[i+1])break;
    }
    if((n<=2) || (i==n))
    {
        pr("-1\n");
        return 0;
    }
    /***************************************/
    for(i=1;i<n;i++)
    {
        for(int j=2;j<=n;j++)
        {
            if(a[i]!=a[j])
            {
                int x;
                x=a[i],a[i]=a[j],a[j]=x;
                int h,f=0,f1;
                for(h=1;h<n;h++)
                {
                    if(a[h]<a[h+1])ans[f++]=1;
                    else if(a[h]>a[h+1])ans[f++]=2;
                }
                for(h=0;h<f-1;h++)
                {
                    if(ans[h]!=ans[h+1])
                    {
                        f1=1;
                        break;
                    }
                }
                if(f1==1)
                {
                    pr("%d %d\n",i,j);
                    return 0;
                }
                x=a[i];
                a[i]=a[j];
                a[j]=x;
            }
        }
    }
    /***************************************/
    pr("-1\n");
    return 0;
}


#include<stdio.h>
#include<string.h>
#include<ctype.h>
#include<math.h>
#include<iostream>
#include<algorithm>
#include<stdlib.h>
#include<vector>
#include<cstdio>
#include<cstring>
#include<cstdlib>
#include<string>
#include<cctype>
#include<cmath>
#define sc scanf
#define pr printf
#define fi first
#define se second
#define si size()
#define pb push_back
#define pf push_front
using namespace std;
int ans[100005],a[100005],b[100005];
main()
{
    //freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);
    int n,i;
    sc("%d",&n);
    for(i=1;i<=n;i++)
    {
        sc("%d",&a[i]);
    }
    if(n<=2)
    {
        pr("-1\n");
        return 0;
    }
    for(i=1;i<=n;i++)
    {
        if(a[i]>a[i+1])ans[i]=1;
        else if(a[i]<a[i+1])ans[i]=2;
        else ans[i]=10;
        if(a[i]>=a[i+1])b[i]=1;
        else b[i]=2;
    }
    for(i=1;i<n;i++)
    {
        if(a[i]!=a[i+1])break;
    }
    if(i==n)
    {
        pr("-1\n");
        return 0;
    }
    for(i=1;i<n-1;i++)
    {
        if(b[i]-b[i+1]!=0)
        {
            break;
        }
    }
    if(i==n-1)
    {
        pr("1 2\n");
        return 0;
    }
    for(i=1;i<n-1;i++)
    {
        if(ans[i] - ans[i+1]==0 || ans[i] - ans[i+1]==0)
        {
            pr("%d %d\n",i,i+1);
            return 0;
        }
        else if(ans[i]!=10 && ans[i+1]==10)
        {
            pr("%d %d\n",i,i+1);
            return 0;
        }
        if(abs(ans[i]-ans[i+1])==1)
        {
            if(a[i]!=a[i+2])
            {
                pr("%d %d\n",i,i+2);
                return 0;
            }
        }
    }
    pr("-1\n");
    return 0;
}


#include<stdio.h>
#include<string.h>
#include<ctype.h>
#include<math.h>
#include<iostream>
#include<algorithm>
#include<stdlib.h>
#include<vector>
#include<cstdio>
#include<cstring>
#include<cstdlib>
#include<string>
#include<cctype>
#include<cmath>
#define sc scanf
#define pr printf
#define fi first
#define se second
#define si size()
#define pb push_back
#define pf push_front
using namespace std;
int ans[100005],a[100005],b[100005];
main()
{
    //freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);
    int n,i;
    sc("%d",&n);
    for(i=1;i<=n;i++)
    {
        sc("%d",&a[i]);
    }
    if(n<=2)
    {
        pr("-1\n");
        return 0;
    }
    for(i=1;i<=n;i++)
    {
        if(a[i]>a[i+1])ans[i]=1;
        else if(a[i]<a[i+1])ans[i]=2;
        else ans[i]=10;
        if(a[i]>=a[i+1])b[i]=1;
        else b[i]=2;
    }
    for(i=1;i<n;i++)
    {
        if(a[i]!=a[i+1])break;
    }
    if(i==n)
    {
        pr("-1\n");
        return 0;
    }
    for(i=1;i<n-1;i++)
    {
        if(b[i]-b[i+1]!=0)
        {
            break;
        }
    }
    if(i==n-1 && a[1]!=10)
    {
        pr("1 2\n");
        return 0;
    }
    for(i=1;i<n-1;i++)
    {
        if(ans[i] - ans[i+1]==0 && ans[i]!=10)
        {
            pr("%d %d\n",i,i+1);
            return 0;
        }
        if(abs(ans[i]-ans[i+1])==1)
        {
            if(a[i]!=a[i+2])
            {
                pr("%d %d\n",i,i+2);
                return 0;
            }
        }
    }
    pr("-1\n");
    return 0;
}


#include<stdio.h>
#include<string.h>
#include<ctype.h>
#include<math.h>
#include<iostream>
#include<algorithm>
#include<stdlib.h>
#include<vector>
#include<cstdio>
#include<cstring>
#include<cstdlib>
#include<string>
#include<cctype>
#include<cmath>
#define sc scanf
#define pr printf
#define fi first
#define se second
#define si size()
#define pb push_back
#define pf push_front
using namespace std;
int ans[100005],a[100005],b[100005];
main()
{
    //freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);
    int n,i;
    sc("%d",&n);
    for(i=1;i<=n;i++){sc("%d",&a[i]);}
    /***************************************/
    for(i=1;i<n;i++)
    {
        if(a[i]!=a[i+1])break;
    }
    if(n<=2 || i==n){pr("-1\n");return 0;}
    /***************************************/
    for(i=1;i<n;i++)
    {
        for(int j=2;j<=n;j++)
        {
            if(a[i]!=a[j])
            {
                swap(a[i],a[j]);
                int h,f=0,f1;
                for(h=1;h<n;h++)
                {
                    if(a[h]<a[h+1])ans[f++]=1;
                    else if(a[h]>a[h+1])ans[f++]=2;
                }
                for(h=0;h<f-1;h++)
                {
                    if(ans[h]!=ans[h+1])
                    {
                        f1=1;
                        break;
                    }
                }
                if(f1==1)
                {
                    pr("%d %d\n",i,j);
                    return 0;
                }
                swap(a[i],a[j]);
            }
        }
    }
    /***************************************/
    pr("-1\n");
    return 0;
}


#include<stdio.h>
#include<string.h>
#include<ctype.h>
#include<math.h>
#include<iostream>
#include<algorithm>
#include<stdlib.h>
#include<vector>
#include<cstdio>
#include<cstring>
#include<cstdlib>
#include<string>
#include<cctype>
#define sc scanf
#define pr printf
#define fi first
#define se second
#define si size()
#define pb push_back
#define pf push_front
using namespace std;
main()
{
    //freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);
    int n,a[100005],i,j,k,k1,ans=0,mv=-1,mx=-1;
    sc("%d",&n);
    for(i=1;i<=n;i++)
    {
        sc("%d",&a[i]);
        if(mv==-1 || mv>a[i])
        {
            mv=a[i];
            k=i;
        }
        if(mx==-1 || mx<a[i])
        {
            mx=a[i];
            k1=i;
        }
    }
    if(n<=2)
    {
        pr("-1\n");
        return 0;
    }
    for(i=1;i<k;i++)
    {
        if(a[i]>mv)
        {
            for(j=i+1;j<k;j++)
            {
                if(a[j]>mv)
                {
                    pr("%d %d\n",k,i);
                    return 0;
                }
            }
            break;
        }
    }
    for(i=k+1;i<=n;i++)
    {
        if(a[i]>mv)
        {
            for(j=i+1;j<=n;j++)
            {
                if(a[j]>mv)
                {
                    pr("%d %d\n",k,i);
                    return 0;
                }
            }
            break;
        }
    }
    for(i=1;i<k1;i++)
    {
        if(a[i]<mx)
        {
            for(j=i+1;j<k1;j++)
            {
                if(a[j]<mx)
                {
                    pr("%d %d\n",k1,i);
                    return 0;
                }
            }
            break;
        }
    }
    for(i=k1+1;i<=n;i++)
    {
        if(a[i]<mx)
        {
            for(j=i+1;j<=n;j++)
            {
                if(a[j]<mx)
                {
                    pr("%d %d\n",k1,i);
                    return 0;
                }
            }
            break;
        }
    }
    pr("-1");
    return 0;
}


# include <iostream>
# include <algorithm>

using namespace std;

const int maxN = 100000 + 10;
int a[maxN];

int main ()
{
    int n;

    cin >> n;

    for (int i = 1 ; i <= n ; i++)
        cin >> a[i];

    if (n < 3)
    {
        cout << 1 - 2;
        return 0;
    }

    for (int i = 1 ; i < n ; i++)
    {
        if (a[i] != a[i + 1])
        {
            swap (a[i] , a[i + 1]);
            bool flagup = false ,  flagdw = false;
            for (int j = 1 ; j < n ; j++)
                if (a[j] > a[j + 1])
                    flagdw = true;
            for (int j = 1 ; j < n ; j++)
                if (a[j] < a[j + 1])
                    flagup = true;

            if (flagup && flagdw)
            {
                cout << i << " " << i + 1;
                return 0;
            }
        }
        if (i == (n - 1))
            cout << 1 - 2;
    }
    cin >> n;
    return 0;
}


/////////////////            In The Name Of Allah            ///////////////////
///// ******************************************************************** /////
// This Programm Is Published By:
//      Milad Rezaei

# include <bitset>
# include <algorithm>
# include <iostream>
# include <fstream>
# include <iomanip>
# include <vector>
# include <set>
# include <map>
# include <deque>
# include <queue>
# include <utility>
# include <cmath>
# include <ctime>
# include <string>
# include <sstream>
# include <fstream>
# include <cstring>
# include <cstdio>
# include <list>
# include <fstream>

using namespace std;

//# define cout fout
//# define cin fin
# define pb push_back
# define time cerr << endl << "time is " << clock() << " ms" << endl
# define printarr(a,n) for (int i = 1 ; i <= n ; i++) cout << a[i] <<" ";
# define getarr(a,n) for (int  i = 1 ; i <= n ; i++) cin >> a[i];
# define printvector(v) for (int i = 0 ; i < v.size() ; i++) cout << v[i] << " ";
# define slark cerr << "slark" << endl;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;

const int maxN = 100000 + 100;
pair < int , int > a[maxN];

int main ()
{
    ios_base::sync_with_stdio(false);
    int n;
    cin >> n;
    for (int i = 1 ; i <= n ; i++)
    {
        cin >> a[i].first;
        a[i].second = i;
    }

    if (n < 3)
    {
        cout << "-1";
        return 0;
    }

    pair < int , int > t1 , t2 , t3;

    t1.first = -1;
    t2.first = -1;
    t3.first = -1;

    t1 = a[1];

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first)
        {
            t2 = a[i];
            break;
        }
    }

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first && a[i].first != t2.first)
        {
            t3 = a[i];
            break;
        }
    }
    int tk = 3;
    if (t1.first == -1)
        tk--;
    if (t2.first == -1)
        tk--;
    if (t3.first == -1)
        tk--;

    if (tk == 1)
    {
        cout << "-1";
    }
    if (tk == 2)
    {
        for (int i = 1 ; i <= n ; i++)
        {
            if (i != t1.second && i != t2.second)
            {
                t3 = a[i];
                break;
            }
        }
        tk = 3;
        if (t1.first == -1)
            tk--;
        if (t2.first == -1)
            tk--;
        if (t3.first == -1)
            tk--;

        if (t1.first == t3.first)
        {
            if (t3.second  > t2.second)
                cout << t1.second << " " << t3.second;
            else
                cout << t3.second << " " << t2.second;
        }

        if (t2.first == t3.first)
            cout << t1.second << " " << t2.second;

    }
    //cout << t1.first << " " << t2.first << " " << t3.first << endl;
    if (tk == 3)
    {
        if (t1.first < t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first < t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first > t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first > t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }
    }

    int _;cin  >> _;
    return 0;
}
///////////////////   Ya ALI


# include <iostream>
# include <algorithm>

using namespace std;

const int maxN = 100000 + 10;
int a[maxN];

int main ()
{
    int n;

    cin >> n;

    for (int i = 1 ; i <= n ; i++)
        cin >> a[i];

    if (n > 3)
    {
        cout << 1 - 2;
        return 0;
    }

    for (int i = 1 ; i < n ; i++)
    {
        if (a[i] != a[i + 1])
        {
            swap (a[i] , a[i + 1]);
            bool flagup = false ,  flagdw = false;
            for (int j = 1 ; j < n ; j++)
                if (a[j] > a[j + 1])
                    flagdw = true;
            for (int j = 1 ; j < n ; j++)
                if (a[j] < a[j + 1])
                    flagup = true;

            if (flagup && flagdw)
            {
                cout << i << " " << i + 1;
                return 0;
            }
        }
        if (i == (n - 1))
            cout << 1 - 2;
    }
    cin >> n;
    return 0;
}


/////////////////            In The Name Of Allah            ///////////////////
///// ******************************************************************** /////
// This Programm Is Published By:
//      Milad Rezaei

# include <bitset>
# include <algorithm>
# include <iostream>
# include <fstream>
# include <iomanip>
# include <vector>
# include <set>
# include <map>
# include <deque>
# include <queue>
# include <utility>
# include <cmath>
# include <ctime>
# include <string>
# include <sstream>
# include <fstream>
# include <cstring>
# include <cstdio>
# include <list>
# include <fstream>

using namespace std;

//# define cout fout
//# define cin fin
# define pb push_back
# define time cerr << endl << "time is " << clock() << " ms" << endl
# define printarr(a,n) for (int i = 1 ; i <= n ; i++) cout << a[i] <<" ";
# define getarr(a,n) for (int  i = 1 ; i <= n ; i++) cin >> a[i];
# define printvector(v) for (int i = 0 ; i < v.size() ; i++) cout << v[i] << " ";
# define slark cerr << "slark" << endl;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;

const int maxN = 100000 + 100;
pair < int , int > a[maxN];

int main ()
{
    ios_base::sync_with_stdio(false);
    int n;
    cin >> n;
    for (int i = 1 ; i <= n ; i++)
    {
        cin >> a[i].first;
        a[i].second = i;
    }

    if (n < 3)
    {
        cout << "-1";
        return 0;
    }

    pair < int , int > t1 , t2 , t3;

    t1.first = -1;
    t2.first = -1;
    t3.first = -1;

    t1 = a[1];

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first)
        {
            t2 = a[i];
            break;
        }
    }

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first && a[i].first != t2.first)
        {
            t3 = a[i];
            break;
        }
    }
    int tk = 3;
    if (t1.first == -1)
        tk--;
    if (t2.first == -1)
        tk--;
    if (t3.first == -1)
        tk--;

    if (tk == 1)
    {
        cout << "-1";
    }
    if (tk == 2)
    {
        for (int i = 1 ; i <= n ; i++)
        {
            if (i != t1.second && i != t2.second)
            {
                t3 = a[i];
                break;
            }
        }
        tk = 3;
        if (t1.first == -1)
            tk--;
        if (t2.first == -1)
            tk--;
        if (t3.first == -1)
            tk--;
        if (tk != 3)
        {
            cout << "-1";
            return 0;
        }

        if (t1.first == t3.first)
        {
            if (t3.second  > t2.second)
                cout << "-1";
            else
                cout << t3.second << " " << t2.second;
        }

        if (t2.first == t3.first)
            cout << t1.second << " " << t2.second;

    }
    //cout << t1.first << " " << t2.first << " " << t3.first << endl;
    if (tk == 3)
    {
        if (t1.first < t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first < t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first > t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first > t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }
    }

    int _;cin  >> _;
    return 0;
}
///////////////////   Ya ALI


# include <iostream>
# include <algorithm>

using namespace std;

const int maxN = 100000 + 10;
int a[maxN];

int main ()
{
    int n;

    cin >> n;

    for (int i = 1 ; i <= n ; i++)
        cin >> a[i];

    if (n < 3)
    {
        cout << 1 - 2;
        return 0;
    }

    for (int i = 1 ; i < n ; i++)
    {
        if (a[i] != a[i + 1])
        {
            swap (a[i] , a[i + 1]);
            bool flagup = false ,  flagdw = false;
            for (int j = 1 ; j < n ; j++)
                if (a[j] > a[j + 1])
                {
                    flagdw = true;
                    break;
                }

            for (int j = 1 ; j < n ; j++)
                if (a[j] < a[j + 1])
                {
                    flagup = true;
                    break;
                }

            if (flagup && flagdw)
            {
                cout << i << " " << i + 1;
                return 0;
            }
            else
            {
                swap (a[i] , a[i + 1]);
            }
        }
        if (i == (n - 1))
            cout << 1 - 2;
    }
    cin >> n;
    return 0;
}


# include <iostream>
# include <algorithm>

using namespace std;

const int maxN = 100000 + 10;
int a[maxN];

int main ()
{
    int n;

    cin >> n;

    for (int i = 1 ; i <= n ; i++)
        cin >> a[i];

    if (n > 3)
    {
        cout << "-1";
        return 0;
    }

    for (int i = 1 ; i < n ; i++)
    {
        if (a[i] != a[i + 1])
        {
            swap (a[i] , a[i + 1]);
            bool flagup = false ,  flagdw = false;
            for (int j = 1 ; j < n ; j++)
                if (a[j] > a[j + 1])
                    flagdw = true;
            for (int j = 1 ; j < n ; j++)
                if (a[j] < a[j + 1])
                    flagup = true;

            if (flagup && flagdw)
            {
                cout << i << " " << i + 1;
                return 0;
            }
        }
        if (i == (n - 1))
            cout << "-1";
    }
    cin >> n;
    return 0;
}


/////////////////            In The Name Of Allah            ///////////////////
///// ******************************************************************** /////
// This Programm Is Published By:
//      Milad Rezaei

# include <bitset>
# include <algorithm>
# include <iostream>
# include <fstream>
# include <iomanip>
# include <vector>
# include <set>
# include <map>
# include <deque>
# include <queue>
# include <utility>
# include <cmath>
# include <ctime>
# include <string>
# include <sstream>
# include <fstream>
# include <cstring>
# include <cstdio>
# include <list>
# include <fstream>

using namespace std;

//# define cout fout
//# define cin fin
# define pb push_back
# define time cerr << endl << "time is " << clock() << " ms" << endl
# define printarr(a,n) for (int i = 1 ; i <= n ; i++) cout << a[i] <<" ";
# define getarr(a,n) for (int  i = 1 ; i <= n ; i++) cin >> a[i];
# define printvector(v) for (int i = 0 ; i < v.size() ; i++) cout << v[i] << " ";
# define slark cerr << "slark" << endl;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;

const int maxN = 100000 + 100;
pair < int , int > a[maxN];

int main ()
{
    ios_base::sync_with_stdio(false);
    int n;
    cin >> n;
    for (int i = 1 ; i <= n ; i++)
    {
        cin >> a[i].first;
        a[i].second = i;
    }

    pair < int , int > t1 , t2 , t3;

    t1.first = -1;
    t2.first = -1;
    t3.first = -1;

    t1 = a[1];

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first)
        {
            t2 = a[i];
            break;
        }
    }

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first && a[i].first != t2.first)
        {
            t3 = a[i];
            break;
        }
    }

    if (t3.first == -1 || t2.first == -1 || t1.first == -1)
    {
        cout << "-1";
        return 0;
    }

    //cout << t1.first << " " << t2.first << " " << t3.first << endl;

    if (t1.first < t2.first && t2.first < t3.first && t1.first < t3.first)
    {
        cout << t2.second << " " << t3.second;
    }

    if (t1.first < t2.first && t2.first > t3.first && t1.first < t3.first)
    {
        cout << t1.second << " " << t2.second;
    }

    if (t1.first < t2.first && t2.first > t3.first && t1.first > t3.first)
    {
        cout << t2.second << " " << t3.second;
    }

    if (t1.first > t2.first && t2.first < t3.first && t1.first < t3.first)
    {
        cout << t2.second << " " << t3.second;
    }

    if (t1.first > t2.first && t2.first < t3.first && t1.first > t3.first)
    {
        cout << t1.second << " " << t2.second;
    }

    if (t1.first > t2.first && t2.first > t3.first && t1.first > t3.first)
    {
        cout << t2.second << " " << t3.second;
    }

    int _;cin  >> _;
    return 0;
}
///////////////////   Ya ALI


/////////////////            In The Name Of Allah            ///////////////////
///// ******************************************************************** /////
// This Programm Is Published By:
//      Milad Rezaei

# include <bitset>
# include <algorithm>
# include <iostream>
# include <fstream>
# include <iomanip>
# include <vector>
# include <set>
# include <map>
# include <deque>
# include <queue>
# include <utility>
# include <cmath>
# include <ctime>
# include <string>
# include <sstream>
# include <fstream>
# include <cstring>
# include <cstdio>
# include <list>
# include <fstream>

using namespace std;

//# define cout fout
//# define cin fin
# define pb push_back
# define time cerr << endl << "time is " << clock() << " ms" << endl
# define printarr(a,n) for (int i = 1 ; i <= n ; i++) cout << a[i] <<" ";
# define getarr(a,n) for (int  i = 1 ; i <= n ; i++) cin >> a[i];
# define printvector(v) for (int i = 0 ; i < v.size() ; i++) cout << v[i] << " ";
# define slark cerr << "slark" << endl;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;

const int maxN = 100000 + 100;
pair < int , int > a[maxN];

int main ()
{
    ios_base::sync_with_stdio(false);
    int n;
    cin >> n;
    for (int i = 1 ; i <= n ; i++)
    {
        cin >> a[i].first;
        a[i].second = i;
    }

    if (n < 3)
    {
        cout << "-1";
        return 0;
    }

    pair < int , int > t1 , t2 , t3;

    t1.first = -1;
    t2.first = -1;
    t3.first = -1;

    t1 = a[1];

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first)
        {
            t2 = a[i];
            break;
        }
    }

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first && a[i].first != t2.first)
        {
            t3 = a[i];
            break;
        }
    }
    int tk = 3;
    if (t1.first == -1)
        tk--;
    if (t2.first == -1)
        tk--;
    if (t3.first == -1)
        tk--;

    if (tk == 1)
    {
        cout << "-1";
    }
    if (tk == 2)
    {
        for (int i = 1 ; i <= n ; i++)
        {
            if (i != t1.second && i != t2.second)
            {
                t3 = a[i];
                break;
            }
        }
        tk = 3;
        if (t1.first == -1)
            tk--;
        if (t2.first == -1)
            tk--;
        if (t3.first == -1)
            tk--;
        if (tk != 3)
        {
            cout << "-1";
            return 0;
        }

        if (t1.first == t3.first)
        {
            if (t3.second  > t2.second)
                cout << t1.second << " " << t3.second;
            else
                cout << t3.second << " " << t2.second;
        }

        if (t2.first == t3.first)
            cout << t1.second << " " << t2.second;

    }
    //cout << t1.first << " " << t2.first << " " << t3.first << endl;
    if (tk == 3)
    {
        if (t1.first < t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first < t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first > t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first > t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }
    }

    int _;cin  >> _;
    return 0;
}
///////////////////   Ya ALI


/////////////////            In The Name Of Allah            ///////////////////
///// ******************************************************************** /////
// This Programm Is Published By:
//      Milad Rezaei

# include <bitset>
# include <algorithm>
# include <iostream>
# include <fstream>
# include <iomanip>
# include <vector>
# include <set>
# include <map>
# include <deque>
# include <queue>
# include <utility>
# include <cmath>
# include <ctime>
# include <string>
# include <sstream>
# include <fstream>
# include <cstring>
# include <cstdio>
# include <list>
# include <fstream>

using namespace std;

//# define cout fout
//# define cin fin
# define pb push_back
# define time cerr << endl << "time is " << clock() << " ms" << endl
# define printarr(a,n) for (int i = 1 ; i <= n ; i++) cout << a[i] <<" ";
# define getarr(a,n) for (int  i = 1 ; i <= n ; i++) cin >> a[i];
# define printvector(v) for (int i = 0 ; i < v.size() ; i++) cout << v[i] << " ";
# define slark cerr << "slark" << endl;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;

const int maxN = 100000 + 100;
pair < int , int > a[maxN];

int main ()
{
    ios_base::sync_with_stdio(false);
    int n;
    cin >> n;
    for (int i = 1 ; i <= n ; i++)
    {
        cin >> a[i].first;
        a[i].second = i;
    }

    pair < int , int > t1 , t2 , t3;

    t1.first = -1;
    t2.first = -1;
    t3.first = -1;

    t1 = a[1];

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first)
        {
            t2 = a[i];
            break;
        }
    }

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first && a[i].first != t2.first)
        {
            t3 = a[i];
            break;
        }
    }
    int tk = 3;
    if (t1.first == -1)
        tk--;
    if (t2.first == -1)
        tk--;
    if (t3.first == -1)
        tk--;

    if (tk == 1)
    {
        cout << "-1";
    }
    if (tk == 2)
    {
        for (int i = 1 ; i <= n ; i++)
        {
            if (i != t1.second && i != t2.second)
            {
                t3 = a[i];
                break;
            }
        }
        tk = 3;
        if (t1.first == -1)
            tk--;
        if (t2.first == -1)
            tk--;
        if (t3.first == -1)
            tk--;

        if (t1.first == t3.first)
        {
            if (t3.second  > t2.second)
                cout << t1.second << " " << t3.second;
            else
                cout << t3.second << " " << t2.second;
        }

        if (t2.first == t3.first)
            cout << t1.second << " " << t2.second;

    }
    //cout << t1.first << " " << t2.first << " " << t3.first << endl;
    if (tk == 3)
    {
        if (t1.first < t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first < t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first > t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first > t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }
    }

    int _;cin  >> _;
    return 0;
}
///////////////////   Ya ALI


# include <iostream>
# include <algorithm>

using namespace std;

const int maxN = 100000 + 10;
int a[maxN];

int main ()
{
    int n;

    cin >> n;

    for (int i = 1 ; i <= n ; i++)
        cin >> a[i];

    if (n < 3)
    {
        cout << 1 - 2;
        return 0;
    }

    for (int i = 1 ; i < n ; i++)
    {
        if (a[i] != a[i + 1])
        {
            swap (a[i] , a[i + 1]);
            bool flagup = false ,  flagdw = false;
            for (int j = 1 ; j < n ; j++)
                if (a[j] > a[j + 1])
                    flagdw = true;
            for (int j = 1 ; j < n ; j++)
                if (a[j] < a[j + 1])
                    flagup = true;

            if (flagup && flagdw)
            {
                cout << i << " " << i + 1;
                return 0;
            }
            else
            {
                swap (a[i] , a[i + 1]);
            }
        }
        if (i == (n - 1))
            cout << 1 - 2;
    }
    cin >> n;
    return 0;
}


/////////////////            In The Name Of Allah            ///////////////////
///// ******************************************************************** /////
// This Programm Is Published By:
//      Milad Rezaei

# include <bitset>
# include <algorithm>
# include <iostream>
# include <fstream>
# include <iomanip>
# include <vector>
# include <set>
# include <map>
# include <deque>
# include <queue>
# include <utility>
# include <cmath>
# include <ctime>
# include <string>
# include <sstream>
# include <fstream>
# include <cstring>
# include <cstdio>
# include <list>
# include <fstream>

using namespace std;

//# define cout fout
//# define cin fin
# define pb push_back
# define time cerr << endl << "time is " << clock() << " ms" << endl
# define printarr(a,n) for (int i = 1 ; i <= n ; i++) cout << a[i] <<" ";
# define getarr(a,n) for (int  i = 1 ; i <= n ; i++) cin >> a[i];
# define printvector(v) for (int i = 0 ; i < v.size() ; i++) cout << v[i] << " ";
# define slark cerr << "slark" << endl;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;

const int maxN = 100000 + 100;
pair < int , int > a[maxN];

int main ()
{
    ios_base::sync_with_stdio(false);
    int n;
    cin >> n;
    for (int i = 1 ; i <= n ; i++)
    {
        cin >> a[i].first;
        a[i].second = i;
    }

    if (n < 3)
    {
        cout << "-1";
        return 0;
    }

    pair < int , int > t1 , t2 , t3;

    t1.first = -1;
    t2.first = -1;
    t3.first = -1;

    t1 = a[1];

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first)
        {
            t2 = a[i];
            break;
        }
    }

    for (int i = 1 ; i <= n ; i++)
    {
        if (a[i].first != t1.first && a[i].first != t2.first)
        {
            t3 = a[i];
            break;
        }
    }
    int tk = 3;
    if (t1.first == -1)
        tk--;
    if (t2.first == -1)
        tk--;
    if (t3.first == -1)
        tk--;

    if (tk == 1)
    {
        cout << "-1";
    }
    if (tk == 2)
    {
        for (int i = 1 ; i <= n ; i++)
        {
            if (i != t1.second && i != t2.second)
            {
                t3 = a[i];
                break;
            }
        }
        tk = 3;
        if (t1.first == -1)
            tk--;
        if (t2.first == -1)
            tk--;
        if (t3.first == -1)
            tk--;
        if (tk != 3)
        {
            cout << "-1";
            return 0;
        }

        if (t1.first == t3.first)
        {
            if (t3.second  > t2.second)
                cout << "-1";
            else
                cout << t3.second << " " << t2.second;
        }

        if (t2.first == t3.first)
        {
            if (t3.second > t2.second)
                cout << t1.second << " " << t2.second;
            else
                cout << t1.second << " " << t3.second;
        }

    }
    //cout << t1.first << " " << t2.first << " " << t3.first << endl;
    if (tk == 3)
    {
        if (t1.first < t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first < t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first < t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first < t3.first)
            {
                cout << t2.second << " " << t3.second;
            }

        if (t1.first > t2.first && t2.first < t3.first && t1.first > t3.first)
            {
                cout << t1.second << " " << t2.second;
            }

        if (t1.first > t2.first && t2.first > t3.first && t1.first > t3.first)
            {
                cout << t2.second << " " << t3.second;
            }
    }

    int _;cin  >> _;
    return 0;
}
///////////////////   Ya ALI


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      scanf("%d",&arr[i]);
      if(n!=2)
       for(int i=0;i<n-1;i++)
       if(arr[i]<arr[i+1])
       {
           cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }
       if(check) cout<<"-1\n";

}


using namespace std;
#include <iostream>
#include <algorithm>
long long a [100100];
int main () {
long long n;
cin >> n;
int x, y = -1, d;
for (int i = 0; i < n; ++i) {
cin >> a [i];
if (!i) {
x = a [0];
d = 0;
} else if (a [i] != x) {
y = i;
}
}
if ( y == -1) cout << y << endl;
else cout << 1 << " " << y + 1 << endl;
return 0;
}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005],brr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      {scanf("%d",&arr[i]);
      brr[i]=arr[i];
      }
       //sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n-2;i++)
       if(arr[i]!=arr[i+1] && arr[i]!=arr[i+2])
       {
           cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }

       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      scanf("%d",&arr[i]);
      sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n-1;i++)
       if(arr[i]<arr[i+1])
       {
           cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }
       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      scanf("%d",&arr[i]);
      //sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n-1;i++)
       if(arr[i]!=arr[i+1])
       {
           cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }
       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      scanf("%d",&arr[i]);
    for(int i=0;i<n-1;i++)
       if(arr[i]<arr[i+1])
       {
           cout<<i<<" "<<i+1<<endl;
           check=false;
           break;
       }
       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005],brr[100005];
int n;
bool asen()
{
    for(int i=0;i<n-1;i++)
    if(brr[i]<brr[i+1])
    return false;
    return true;
}
bool desen()
{
    for(int i=0;i<n-1;i++)
    if(brr[i]>brr[i+1])
    return false;
    return true;
}
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;

    scanf("%d",&n);
    for(int i=0;i<n;i++)
      {scanf("%d",&arr[i]);
      brr[i]=arr[i];
      }
     //  sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n;i++)
       if(arr[i]!=arr[i+1])
       {
           swap(brr[i],brr[i+1]);
           if( asen() || desen())
           {

                 swap(brr[i],brr[i+1]);

           }
           else
           {
                 cout<<i+1<<" "<<i+2<<endl;
               check=false;
               break;
           }

       }

       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005],brr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      {scanf("%d",&arr[i]);
      brr[i]=arr[i];
      }
       sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n-2;i++)
       if(arr[i]!=arr[i+1] && arr[i]!=arr[i+2])
       {
           cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }

       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005],brr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      {scanf("%d",&arr[i]);
      brr[i]=arr[i];
      }
       //sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n-2;i++)
       if(arr[i]<arr[i+1] && arr[i]<arr[i+2])
       {
           cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }
       else if(arr[i]>arr[i+1] && arr[i]>arr[i+2])
       {
             cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }
       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      scanf("%d",&arr[i]);
      if(n!=2)
       for(int i=0;i<n-1;i++)
       if(arr[i]<arr[i+1])
       {
           cout<<i<<" "<<i+1<<endl;
           check=false;
           break;
       }
       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005];
int n;
bool is_sort()
{   int asen=0,desen=0;
    for(int i=0;i<n-1;i++)
    if(arr[i]<arr[i+1])
    asen++;
    else if (arr[i]>arr[i+1]) desen++;
    if(asen==0 || desen==0)
    return true;
    return false;
}

int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;

    scanf("%d",&n);
    for(int i=0;i<n;i++) scanf("%d",&arr[i]);
      if(n!=2)
       for(int i=0;i<n-1;i++)
       if(arr[i]!=arr[i+1])
       {
           swap(arr[i],arr[i+1]);
           if( is_sort())
           {

                 swap(arr[i],arr[i+1]);

           }
           else
           {
               cout<<i+1<<" "<<i+2<<endl;
               check=false;
               break;
           }

       }

       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005];
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;
    int n;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
      scanf("%d",&arr[i]);
      sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n-1;i++)
       if(arr[i]!=arr[i+1])
       {
           cout<<i+1<<" "<<i+1+1<<endl;
           check=false;
           break;
       }
       if(check) cout<<"-1\n";

}


//BISMILLAHIRRAHMANIRRAHIM
/*
 manus tar shopenr soman boro
 Author :: Shakil Ahmed
 prob   ::
 Type   ::
 */
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#include <algorithm>
#include <iostream>
#include <vector>
#include <stack>
#include <string>
#include <list>
#include <map>
#include <queue>
#include <sstream>
#include <utility>
#define pf printf
#define sc scanf
#define pb push_back
#define mp make_pair
#define pi acos(-1.0)
#define LL long long
#define ff first
#define ss second
#define rep(i,n) for(int i = 0; i < n; i++)
#define REP(i,n) for(int i=n;i>=0;i--)
#define ROF(i,a,b) for(int i = a; i <= b; i++)
#define rof(i,a,b) for(int i = a; i >= b; i--)
#define re return
#define QI queue<int>
#define SI stack<int>
#define pii pair <int,int>
#define MAX 1000000
#define INF 1<<29
#define sz(x) ((int) (x).size())
#define all(x) (x).begin(), (x).end()
#define sqr(x) ((x) * (x))

using namespace std;

template<class T> T abs(T x) {re x > 0 ? x : -x;}
template< class T > T gcd(T a, T b) { return (b != 0 ? gcd<T>(b, a%b) : a); }
template< class T > T lcm(T a, T b) { return (a / gcd<T>(a, b) * b); }

int arr[100005],brr[100005];
int n;
bool asen()
{
    for(int i=0;i<n-1;i++)
    if(brr[i]<brr[i+1])
    return false;
    return true;
}
bool desen()
{
    for(int i=0;i<n-1;i++)
    if(brr[i]>brr[i+1])
    return false;
    return true;
}
int main()
{    //freopen("input.txt","r",stdin);
    bool check=true;

    scanf("%d",&n);
    for(int i=0;i<n;i++)
      {scanf("%d",&arr[i]);
      brr[i]=arr[i];
      }
     //  sort(arr,arr+n);
      if(n!=2)
       for(int i=0;i<n-1;i++)
       if(arr[i]!=arr[i+1])
       {
           swap(brr[i],brr[i+1]);
           if( asen() || desen())
           {

                 swap(brr[i],brr[i+1]);

           }
           else
           {
               cout<<i+1<<" "<<i+2<<endl;
               check=false;
               break;
           }

       }

       if(check) cout<<"-1\n";

}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in(){int r=0,c;for(c=getchar();c<=32;c=getchar());if(c=='-') return -in();for(;c>32;r=(r<<1)+(r<<3)+c-'0',c=getchar());return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
    //std::ios::sync_with_stdio(false);
    //freopen("","r",stdin);
    //freopen("","w",stdout);
	int n;
	cin>>n;
	int v[n], v2[n];
	for (int i = 0; i < n; ++i)
	{
		cin>>v[i];
		v2[i] = v[i];
	}
	if (n <= 2 || v[0] == v[n-1])
	{
		cout<<-1<<endl;
		return 0;
	}
	bool swaped = false;
	if (v[0] > v[n-1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	bool sorted = true;
	for (int i = 0; i < n; i++)
	{
		if (v[i] != v2[i]) sorted = false;
	}
	if (sorted)
	{
		if (swaped) reverse(v, v + n);
		int a = 1, b = 2;
		while (v[a] == v[b]) b++;
		cout<<a+1<<" "<<b+1<<endl;
	}
	else cout<<1<<" "<<n<<endl;
    return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in(){int r=0,c;for(c=getchar();c<=32;c=getchar());if(c=='-') return -in();for(;c>32;r=(r<<1)+(r<<3)+c-'0',c=getchar());return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
    //std::ios::sync_with_stdio(false);
    //freopen("","r",stdin);
    //freopen("","w",stdout);
	int n;
	cin>>n;
	int v[n], v2[n];
	for (int i = 0; i < n; ++i)
	{
		cin>>v[i];
		v2[i] = v[i];
	}
	if (n <= 2 || v[0] == v[n-1])
	{
		cout<<-1<<endl;
		return 0;
	}
	bool swaped = false;
	if (v[0] > v[n-1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	bool sorted = true;
	for (int i = 0; i < n; i++)
	{
		if (v[i] != v2[i]) sorted = false;
	}
	if (sorted)
	{
		if (swaped) reverse(v, v + n);
		int x = 0;
		while (v[0] == v[x]) x++;
		cout<<x<<" "<<x+1<<endl;
	}
	else cout<<1<<" "<<n<<endl;
    return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	bool swaped = false;
	if (v[0] > v[n - 1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	if (n <= 2 || v2[0] == v2[n - 1])
	{
		cout << -1 << endl;
		return 0;
	}
	if (n == 3)
	{
		if (v[0] == v[2] && v[0] != v[1])
		{
			cout << -1 << endl;
			return 0;
		}
	}
	bool sorted = true;
	for (int i = 0; i < n; i++)
	{
		if (v[i] != v2[i]) sorted = false;
	}
	if (sorted)
	{
		if (swaped) reverse(v, v + n);
		int x = 0;
		while (v[0] == v[x]) x++;
		cout << x << " " << x + 1 << endl;
	}
	else
	{
		if (swaped) reverse(v, v + n);
		map<int, int>::iterator i1, i2;
		i1 = m.begin();
		i2 = m.end(); i2--;
		v[i1 -> second] = i2 -> first;
		v[i2 -> second] = i1 -> first;
		if (swaped) reverse(v, v + n);
		if (v[0] > v[n - 1]) reverse(v, v + n);
		sorted = true;
		for (int i = 0; i < n; i++)
		{
			if (v[i] != v2[i]) sorted = false;
		}
		if (!sorted) cout << i1 -> second + 1 << " " << i2 -> second + 1 << endl;
		else
		{
			i1++;
			cout << i1 -> second + 1 << " " << i2 -> second + 1 << endl;
		}
	}
	return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	bool swaped = false;
	if (v[0] > v[n - 1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	bool sol = false;
	for (int i = 0; i < n-1; i++)
	{
		if (v[i] == v[i+1]) continue;
		swap(v[i], v[i+1]);
		int j = 0;
		while (j < n && v[j] == v2[j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		j = 0;
		while (j < n && v[j] == v2[n - 1 - j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		cout<<i+1<<" "<<i+2<<endl;
		sol = true;
		break;
	}
	if (!sol) cout<<-1<<endl;
	return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	sort(v2, v2 + n);
	bool sol = false;
	for (int i = 0; i < n-1; i++)
	{
		if (v[i] == v[i+1]) continue;
		swap(v[i], v[i+1]);
		int j = 0;
		while (j < n && v[j] == v2[j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		j = 0;
		while (j < n && v[j] == v2[n - 1 - j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		cout<<i+1<<" "<<i+2<<endl;
		return 0;
	}
	cout<<-1<<endl;
	return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	bool swaped = false;
	if (v[0] > v[n - 1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	bool sol = false;
	for (int i = 0; i < n-1; i++)
	{
		if (v[i] == v[i+1]) continue;
		swap(v[i], v[i+1]);
		int j = 0;
		while (j < n && v[j] == v2[j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		while (j < n && v[j] == v2[n - 1 - j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		cout<<i+1<<" "<<i+2<<endl;
		sol = true;
		break;
	}
	if (!sol) cout<<-1<<endl;
	return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	bool swaped = false;
	if (v[0] > v[n - 1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	if (n <= 2 || v2[0] == v2[n - 1])
	{
		cout << -1 << endl;
		return 0;
	}
	bool sorted = true;
	for (int i = 0; i < n; i++)
	{
		if (v[i] != v2[i]) sorted = false;
	}
	if (sorted)
	{
		if (swaped) reverse(v, v + n);
		int x = 0;
		while (v[0] == v[x]) x++;
		cout << x << " " << x + 1 << endl;
	}
	else
	{
		if (swaped) reverse(v, v + n);
		map<int, int>::iterator i1, i2;
		i1 = m.begin();
		i2 = m.end(); i2--;
		v[i1 -> second] = i2 -> first;
		v[i2 -> second] = i1 -> first;
		if (swaped) reverse(v, v + n);
		if (v[0] > v[n-1]) reverse(v, v + n);
		sorted = true;
		for (int i = 0; i < n; i++)
		{
			if (v[i] != v2[i]) sorted = false;
		}
		if (!sorted) cout << i1 -> second + 1 << " " << i2 -> second + 1 << endl;
		else
		{
			i1++;
			cout << i1 -> second + 1 << " " << i2 -> second + 1 << endl;
		}
	}
	return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	bool swaped = false;
	if (v[0] > v[n - 1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	for (int i = 0; i < n-1; i++)
	{
		if (v[i] == v[i+1]) continue;
		swap(v[i], v[i+1]);
		int j = 0;
		while (j < n && v[j] == v2[j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		while (j < n && v[j] == v2[n - 1 - j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		cout<<i+1<<" "<<i+2<<endl;
		break;
	}
	cout<<-1<<endl;
	return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	if (n <= 2 || v[0] == v[n - 1])
	{
		cout << -1 << endl;
		return 0;
	}
	bool swaped = false;
	if (v[0] > v[n - 1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	bool sorted = true;
	for (int i = 0; i < n; i++)
	{
		if (v[i] != v2[i]) sorted = false;
	}
	if (sorted)
	{
		if (swaped) reverse(v, v + n);
		int x = 0;
		while (v[0] == v[x]) x++;
		cout << x << " " << x + 1 << endl;
	}
	else
	{
		if (swaped) reverse(v, v + n);
		map<int, int>::iterator i1, i2;
		i1 = m.begin();
		i2 = m.end(); i2--;
		v[i1 -> second] = i2 -> first;
		v[i2 -> second] = i1 -> first;
		if (swaped) reverse(v, v + n);
		if (v[0] > v[n-1]) reverse(v, v + n);
		sorted = true;
		for (int i = 0; i < n; i++)
		{
			if (v[i] != v2[i]) sorted = false;
		}
		if (!sorted) cout << i1 -> second + 1 << " " << i2 -> second + 1 << endl;
		else
		{
			i1++;
			cout << i1 -> second + 1 << " " << i2 -> second + 1 << endl;
		}
	}
	return 0;
}


#include <bits/stdc++.h>
#define PI                3.14159265358979323846264338327950
#define pb                push_back
#define mp                make_pair
#define all(a)            (a).begin(), (a).end()
#define clr(a,h)          memset(a, (h), sizeof(a))
#define F first
#define S second
int in() {int r = 0, c; for (c = getchar(); c <= 32; c = getchar()); if (c == '-') return -in(); for (; c > 32; r = (r << 1) + (r << 3) + c - '0', c = getchar()); return r;}

using namespace std;

const int INF = int(1e9 + 7);
typedef pair<int, int>  ii;
typedef vector<int>     vi;
typedef vector<ii>      vii;
typedef long long       ll;
typedef vector<ll>      vll;

int main()
{
	//std::ios::sync_with_stdio(false);
	//freopen("","r",stdin);
	//freopen("","w",stdout);
	int n;
	cin >> n;
	int v[n], v2[n];
	map<int, int> m;
	for (int i = 0; i < n; ++i)
	{
		cin >> v[i];
		m[v[i]] = i;
		v2[i] = v[i];
	}
	bool swaped = false;
	if (v[0] > v[n - 1])
	{
		swaped = true;
		reverse(v, v + n);
	}
	sort(v2, v2 + n);
	for (int i = 0; i < n-1; i++)
	{
		if (v[i] == v[i+1]) continue;
		swap(v[i], v[i+1]);
		int j = 0;
		while (j < n && v[j] == v2[j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		while (j < n && v[j] == v2[n - 1 - j]) j++;
		if (j == n)
		{
			swap(v[i], v[i+1]);
			continue;
		}
		cout<<i+1<<" "<<i+2<<endl;
		break;
	}
	return 0;
}


#include <cstdio>
#include <iostream>
#include <algorithm>

using namespace std;

#define ff(i,a,b) for (int i = a; i < b; ++i)
#define sc scanf
#define pr printf
#define MAX 100100

int n, a[MAX], b[MAX], s, cnt, x, y;

int main()
{
	sc("%d",&n);

	if (n == 1 || n == 2)
	{
		for (int i = 0; i < n; ++i) sc("%d",&a[i]);
		pr("-1");
		return 0;
	}

	ff(i,0,n)
	{
		sc("%d",&a[i]);
		if (s != 2)
		{
			if (i >= 1)
			{
				if (a[i-1] < a[i])
				{
					if (s == 1) s = 2;
					else s = -1;
				}
				else if (a[i-1] > a[i])
				{
					if (s == -1) s = 2;
					else s = 1;
				}
			}
		}
	}

	if (s != 2)
	{
		if (a[0] == a[n-1]) pr("-1");
		else
		{
			int t = a[n-1];
			a[n-1] = a[0];
			a[0] = t;
			if (s == -1)
			{
				ff(i,0,n-1)
					if (a[i] < a[i+1])
					{
						pr("1 %d", n);
						return 0;
					}
			}
			else
			{
				ff(i,0,n-1)
					if (a[i] > a[i+1])
					{
						pr("1 %d", n);
						return 0;
					}
			}
			pr("-1");
		}
	}
	else
	{
		ff(i,0,n) b[i] = a[i];
		stable_sort(b, b+n);
		ff(i,0,n)
		{
			if (b[i] != a[i]) ++cnt;
			if (cnt == 1) x = i;
			else if (cnt == 2) y = i;
			else if (cnt > 2)
			{
				pr("%d %d", x+1, y+1);
				return 0;
			}
		}
		pr("%d ", x+1);
		ff(i,0,n)
			if (a[i] != a[y])
			{
				pr("%d", i+1);
				break;
			}
	}

	return 0;
}


/*-------------icalFikr's template v2.2--------------*/

#include <iostream>
#include <cstdio>
#include <fstream>
#include <string>
#include <cstring>
#include <vector>
#include <list>
#include <map>
#include <bitset>
#include <stack>
#include <queue>
#include <deque>
#include <set>
#include <cstdlib>
#include <cmath>
#include <complex>
#include <algorithm>
#include <iomanip>
#include <cstddef>
#include <cassert>
#include <cctype>
#include <utility>
#include <ctime>

#ifndef GEDEBUG
	#define DEBUG printf(__VA_ARGS__)
	#define DEBUGS puts("gukguk")
	#define TIME() printf("\nFinished in %.3lf s\n",clock()/(double)CLOCKS_PER_SEC)
#endif

/* Abbreviations */
#define puf push_front
#define pof pop_front()
#define pub push_back
#define pob pop_back()
#define fs first
#define sc second
#define mp make_pair
#define FOR(i,a,b) for(int i=int(a),_b=int(b);i<=_b;i++)
#define FORINC(i,a,b,inc) for(int i=int(a),_b=int(b);i<=_b;i+=inc)
#define FORLL(i,a,b) for(LL i=LL(a),_b=LL(b);i<=_b;i++)
#define FORD(i,a,b) for(int i=int(a),_b=int(b);i>=_b;i--)
#define FOREACH(i,a) for (__typeof(a.begin()) i=a.begin();i!=a.end();i++)
#define OPEN freopen("input.txt","r",stdin); freopen("output.txt","w",stdout);
#define CLOSE fclose(stdin); fclose(stdout);
#define ALL(v) (v).begin(),(v).end()
#define sz size()
#define reset(x,N) memset(x,N,sizeof(x))
#define nl puts("")
#ifdef __WIN32__
    #define gc getchar()
#else
    #define gc getchar_unlocked()
#endif

using namespace std;
typedef double db;
typedef long long LL;
typedef pair <int,int> ii;
typedef pair <LL,LL> pll;
typedef vector <ii> vii;
typedef vector <int> vint;

const db EPS	= 0.0000001;
const db PI 	= acos(-1);
const LL INFLL	= 0x7FFFFFFFFFFFFFFF;
const int INF	= 0x7FFFFFFF;

template<typename T>
inline void next(T &num) {
    char c; num=0;
    do { c=gc; }
    while (c!=EOF && c==' ' && c=='\n' && c=='\t');
    int sign=(c=='-' ? -1 : 1);
    if (c!='-') num+=(c-'0');
    while ( (c=gc)!=EOF && c!='\n' && c!='\t' && c!=' ') {
        num*=10; num+=(c-'0');
    }
    num*=sign;
}

inline string getstr() {
    string str; char k;
    while( (k=gc)==' ' || k=='\n' ) {
        k=gc;
        if ( k==' ' || k=='\n' ) continue;
        else break;
    }
	str.pub(k);
    while((k=gc)!=EOF &&k!='\n' && k!='\t'
        && k!='\v' && k!='\0' && k!=' ')
        str.pub(k);
    return str;
}

/*-------------end of template-------------*/
int a[100005], n;
bool _inc = 1, _dec = 1;
map<int,int> last;

int main() {
    ios_base::sync_with_stdio(0);
    cin.tie(0);

    #ifndef ONLINE_JUDGE
        //freopen("input.txt","rt",stdin);
    #endif

    cin >> n;
    FOR(i,0,n-1) {
        cin >> a[i];
        last[a[i]] = i;
    }

    if (n < 3) { cout << -1; return 0; }

    FOR(i,1,n-1) {
        _inc &= (a[i] >= a[i-1]);
        _dec &= (a[i] <= a[i-1]);
    }

    if ((_inc || _dec))
        if (a[0] != a[n-1]) {
            FOR(i,0,n-2)
                if (a[i] != a[i+1]) {
                    cout << i+1 << ' ' << i+2;
                    return 0;;
                }
        } else { cout << -1; return 0; }

    if (n < 4) {
        FOR(i,0,1) FOR(j,i+1,2)
        if (a[i] != a[j]) {
            swap(a[i],a[j]);
            _inc = 1, _dec = 1;

            FOR(i,1,2) {
                _inc &= (a[i] >= a[i-1]);
                _dec &= (a[i] <= a[i-1]);
            }

            if (!_inc && !_dec) {
                cout << i + 1 << ' ' << j + 1;
                return 0;
            } else swap(a[i],a[j]);
        }
        cout << -1;
        return 0;
    }

    FORD(i,n-1,1)
    if (a[0] != a[i]) {
        cout << last[a[i]] + 1 << ' ' << i + 1;
        break;
    }

    return 0;
}


/*-------------icalFikr's template v2.2--------------*/

#include <iostream>
#include <cstdio>
#include <fstream>
#include <string>
#include <cstring>
#include <vector>
#include <list>
#include <map>
#include <bitset>
#include <stack>
#include <queue>
#include <deque>
#include <set>
#include <cstdlib>
#include <cmath>
#include <complex>
#include <algorithm>
#include <iomanip>
#include <cstddef>
#include <cassert>
#include <cctype>
#include <utility>
#include <ctime>

#ifndef GEDEBUG
	#define DEBUG printf(__VA_ARGS__)
	#define DEBUGS puts("gukguk")
	#define TIME() printf("\nFinished in %.3lf s\n",clock()/(double)CLOCKS_PER_SEC)
#endif

/* Abbreviations */
#define puf push_front
#define pof pop_front()
#define pub push_back
#define pob pop_back()
#define fs first
#define sc second
#define mp make_pair
#define FOR(i,a,b) for(int i=int(a),_b=int(b);i<=_b;i++)
#define FORINC(i,a,b,inc) for(int i=int(a),_b=int(b);i<=_b;i+=inc)
#define FORLL(i,a,b) for(LL i=LL(a),_b=LL(b);i<=_b;i++)
#define FORD(i,a,b) for(int i=int(a),_b=int(b);i>=_b;i--)
#define FOREACH(i,a) for (__typeof(a.begin()) i=a.begin();i!=a.end();i++)
#define OPEN freopen("input.txt","r",stdin); freopen("output.txt","w",stdout);
#define CLOSE fclose(stdin); fclose(stdout);
#define ALL(v) (v).begin(),(v).end()
#define sz size()
#define reset(x,N) memset(x,N,sizeof(x))
#define nl puts("")
#ifdef __WIN32__
    #define gc getchar()
#else
    #define gc getchar_unlocked()
#endif

using namespace std;
typedef double db;
typedef long long LL;
typedef pair <int,int> ii;
typedef pair <LL,LL> pll;
typedef vector <ii> vii;
typedef vector <int> vint;

const db EPS	= 0.0000001;
const db PI 	= acos(-1);
const LL INFLL	= 0x7FFFFFFFFFFFFFFF;
const int INF	= 0x7FFFFFFF;

template<typename T>
inline void next(T &num) {
    char c; num=0;
    do { c=gc; }
    while (c!=EOF && c==' ' && c=='\n' && c=='\t');
    int sign=(c=='-' ? -1 : 1);
    if (c!='-') num+=(c-'0');
    while ( (c=gc)!=EOF && c!='\n' && c!='\t' && c!=' ') {
        num*=10; num+=(c-'0');
    }
    num*=sign;
}

inline string getstr() {
    string str; char k;
    while( (k=gc)==' ' || k=='\n' ) {
        k=gc;
        if ( k==' ' || k=='\n' ) continue;
        else break;
    }
	str.pub(k);
    while((k=gc)!=EOF &&k!='\n' && k!='\t'
        && k!='\v' && k!='\0' && k!=' ')
        str.pub(k);
    return str;
}

/*-------------end of template-------------*/
int a[100005], last[100005], first[100005], n;
bool _inc, _dec;

void cek() {
    _inc = 1, _dec = 1;

    FOR(i,1,n-1) {
        _inc &= (a[i] >= a[i-1]);
        _dec &= (a[i] <= a[i-1]);
    }
}

int main() {
    ios_base::sync_with_stdio(0);
    cin.tie(0);

    #ifndef ONLINE_JUDGE
        freopen("input.txt","rt",stdin);
    #endif

    cin >> n;
    FOR(i,0,n-1) cin >> a[i];

    last[n-1] = n-1;
    FORD(i,n-2,0) last[i] = a[i] == a[i+1] ? last[i+1] : i;

    first[0] = 0;
    FOR(i,1,n-1) first[i] = a[i] == a[i-1] ? first[i-1] : i;

    if (n < 3) { cout << -1; return 0; }

    cek();

    if ((_inc || _dec))
        if (a[0] != a[n-1]) {
            FOR(i,0,n-2)
                if (a[i] != a[i+1]) {
                    cout << i+1 << ' ' << i+2;
                    return 0;;
                }
        } else { cout << -1; return 0; }

    if (n < 4) {
        FOR(i,0,1) FOR(j,i+1,2)
        if (a[i] != a[j]) {
            swap(a[i],a[j]);

            cek();

            if (!_inc && !_dec) {
                cout << i + 1 << ' ' << j + 1;
                return 0;
            } else swap(a[i],a[j]);
        }
        cout << -1;
        return 0;
    }

    int ans1 = n-1, ans2 = 0;
    while(ans1 >= 0 && a[ans1] == a[0]) ans1--;
    while(ans2 < n && a[ans2] == a[n-1]) ans2++;

    swap(a[last[0]],a[ans1]);
    cek();
    if (!_inc && !_dec) {
        cout << last[0] + 1 << ' ' << ans1 + 1;
        return 0;
    }
    swap(a[last[0]],a[ans1]);   //netralizer

    swap(a[first[n-1]],a[ans2]);
    cek();
    if (!_inc && !_dec) {
        cout << first[n-1] + 1 << ' ' << ans2 + 1;
    }

    return 0;
}


/*-------------icalFikr's template v2.2--------------*/

#include <iostream>
#include <cstdio>
#include <fstream>
#include <string>
#include <cstring>
#include <vector>
#include <list>
#include <map>
#include <bitset>
#include <stack>
#include <queue>
#include <deque>
#include <set>
#include <cstdlib>
#include <cmath>
#include <complex>
#include <algorithm>
#include <iomanip>
#include <cstddef>
#include <cassert>
#include <cctype>
#include <utility>
#include <ctime>

#ifndef GEDEBUG
	#define DEBUG printf(__VA_ARGS__)
	#define DEBUGS puts("gukguk")
	#define TIME() printf("\nFinished in %.3lf s\n",clock()/(double)CLOCKS_PER_SEC)
#endif

/* Abbreviations */
#define puf push_front
#define pof pop_front()
#define pub push_back
#define pob pop_back()
#define fs first
#define sc second
#define mp make_pair
#define FOR(i,a,b) for(int i=int(a),_b=int(b);i<=_b;i++)
#define FORINC(i,a,b,inc) for(int i=int(a),_b=int(b);i<=_b;i+=inc)
#define FORLL(i,a,b) for(LL i=LL(a),_b=LL(b);i<=_b;i++)
#define FORD(i,a,b) for(int i=int(a),_b=int(b);i>=_b;i--)
#define FOREACH(i,a) for (__typeof(a.begin()) i=a.begin();i!=a.end();i++)
#define OPEN freopen("input.txt","r",stdin); freopen("output.txt","w",stdout);
#define CLOSE fclose(stdin); fclose(stdout);
#define ALL(v) (v).begin(),(v).end()
#define sz size()
#define reset(x,N) memset(x,N,sizeof(x))
#define nl puts("")
#ifdef __WIN32__
    #define gc getchar()
#else
    #define gc getchar_unlocked()
#endif

using namespace std;
typedef double db;
typedef long long LL;
typedef pair <int,int> ii;
typedef pair <LL,LL> pll;
typedef vector <ii> vii;
typedef vector <int> vint;

const db EPS	= 0.0000001;
const db PI 	= acos(-1);
const LL INFLL	= 0x7FFFFFFFFFFFFFFF;
const int INF	= 0x7FFFFFFF;

template<typename T>
inline void next(T &num) {
    char c; num=0;
    do { c=gc; }
    while (c!=EOF && c==' ' && c=='\n' && c=='\t');
    int sign=(c=='-' ? -1 : 1);
    if (c!='-') num+=(c-'0');
    while ( (c=gc)!=EOF && c!='\n' && c!='\t' && c!=' ') {
        num*=10; num+=(c-'0');
    }
    num*=sign;
}

inline string getstr() {
    string str; char k;
    while( (k=gc)==' ' || k=='\n' ) {
        k=gc;
        if ( k==' ' || k=='\n' ) continue;
        else break;
    }
	str.pub(k);
    while((k=gc)!=EOF &&k!='\n' && k!='\t'
        && k!='\v' && k!='\0' && k!=' ')
        str.pub(k);
    return str;
}

/*-------------end of template-------------*/
int a[100005], last[100005], first[100005], n;
bool _inc, _dec;

void cek() {
    _inc = 1, _dec = 1;

    FOR(i,1,2) {
        _inc &= (a[i] >= a[i-1]);
        _dec &= (a[i] <= a[i-1]);
    }
}

int main() {
    ios_base::sync_with_stdio(0);
    cin.tie(0);

    #ifndef ONLINE_JUDGE
        //freopen("input.txt","rt",stdin);
    #endif

    cin >> n;
    FOR(i,0,n-1) cin >> a[i];

    last[n-1] = n-1;
    FORD(i,n-2,0) last[i] = a[i] == a[i+1] ? last[i+1] : i;

    first[0] = 0;
    FOR(i,1,n-1) first[i] = a[i] == a[i-1] ? first[i-1] : i;

    if (n < 3) { cout << -1; return 0; }

    cek();

    if ((_inc || _dec))
        if (a[0] != a[n-1]) {
            FOR(i,0,n-2)
                if (a[i] != a[i+1]) {
                    cout << i+1 << ' ' << i+2;
                    return 0;;
                }
        } else { cout << -1; return 0; }

    if (n < 4) {
        FOR(i,0,1) FOR(j,i+1,2)
        if (a[i] != a[j]) {
            swap(a[i],a[j]);

            cek();

            if (!_inc && !_dec) {
                cout << i + 1 << ' ' << j + 1;
                return 0;
            } else swap(a[i],a[j]);
        }
        cout << -1;
        return 0;
    }

    int ans1 = n-1, ans2 = 0;
    while(a[ans1] == a[0]) ans1--;
    while(a[ans2] == a[n-1]) ans2++;

    swap(a[last[0]],a[ans1]);
    cek();
    if (!_inc && !_dec) {
        cout << last[0] + 1 << ' ' << ans1 + 1;
        return 0;
    } else swap(a[last[0]],a[ans1]);

    swap(a[first[n-1]],a[ans2]);
    if (!_inc && !_dec) {
        cout << first[n-1] + 1 << ' ' << ans2 + 1;
        break;
    }

    return 0;
}