Language: C++

#include<bits/stdc++.h>
#define ll long long int
#include <stdlib.h>
#include <vector>
#define pi acos(-1)
#define MOD 1000000007
#define highest(x) numeric_limits<x>::max()
#define lowest(x) numeric_limits<x>::min()
///s1.substr(1,3);///STARTING FROM INDEX 1, 3 LNEGTH SUBSTRING.
///s1.find("adn")///RETURNS STARTING INDEX OF THE SUBSTRING
///"adn" IF IT EXISTS IN THE STRING S1.///
///s1.find("adn",int pos);///RETURNS STARTING INDEX OF THE
///SUBSTRING "adn" SEARCHING FROM INDEX POS OF STRING s1.///
///string::npos returns a garbage value if not found...
///reverse(s1.begin(),s1.end())-> to reverse a string.
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define gcd(a,b) __gcd(a,b)
using namespace std;



//vector<int>prime(8000000,0);
vector<bool>mark(100000000,false);
int prime[8000000];
int nprime;

void sieve(int n)
{
    int limit=sqrt(n*1.0)+1,s=0;nprime=0;
    mark[1]=true;///1 if not prime.
    mark[2]=false;prime[nprime++]=2;//cout<<2<<endl;
    for(int i=4;i<=n;i+=2)mark[i]=true;
    for(int i=3;i<=n;i+=2){
        if(!mark[i]){prime[nprime++]=i;//cout<<i<<endl;
        if(i<=limit){///karon limit er upor theke n porjonto not prime gula already cuta hoise.
            for(int j=i*i;j<=n;j+=i*2){
                mark[j]=true;
            }
          }
        }
    }
    //puts("2");
    //cout<<nprime<<endl;
    for(int i=1;i<=nprime;i+=100)cout<<prime[i-1]<<endl;
    //return nprime;
}
int l1[100005],l2[100005];
int main()
{
    //freopen("input.in", "r", stdin);
    //freopen("output.out", "w", stdout);
    ll t,i,q,n,k,l,c,d,p,nl,np,a,e,m,b=0,x1=1000000005,x3=0,x4=0,x5=0,x6=0;
    //double x10=0;
    //string s2,s3,s4,s5,s6,s7;
    map<ll,ll>m1,m2;
    cin>>n;
    for(int i=1;i<=n;i++){
        cin>>l1[i];
    }
    for(int i=1;i<=n;i++){
        x1=min(x1,l1[i]);
        if(x1==l[i])b++;
    }
    cout<<b<<endl;

    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:61:15: error: no matching function for call to 'min(long long int&, int&)'
   61 |         x1=min(x1,l1[i]);
      |            ~~~^~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
  233 |     min(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:233:5: note:   template argument deduction/substitution failed:
a.cc:61:15: note:   deduced conflicting types for parameter 'const _Tp' ('long long int' and 'int')
   61 |         x1=min(x1,l1[i]);
      |            ~~~^~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:281:5: note:   candidate expects 3 arguments, 2 provided
In file included from /usr/include/c++/14/algorithm:61:
/usr/include/c++/14/bits/stl_algo.h:5686:5: note: candidate: 'template<class _Tp> constexpr _Tp std::min(initializer_list<_Tp>)'
 5686 |     min(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5686:5: note:   candidate expects 1 argument, 2 provided
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::min(initializer_list<_Tp>, _Compare)'
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note:   template argument deduction/substitution failed:
a.cc:61:15: note:   mismatched types 'std::initializer_list<_Tp>' and 'long long int'
   61 |         x1=min(x1,l1[i]);
      |            ~~~^~~~~~~~~~
a.cc:62:17: error: invalid types 'long long int[int]' for array subscript
   62 |         if(x1==l[i])b++;
      |                 ^