Language: C++

#include<iostream>
#include<string>
#include<cstdio>
#include <cstring>
#include<vector>
#include<cmath>
#include<algorithm>
#include<functional>
#include<iomanip>
#include<queue>
#include<ciso646>
#include<random>
#include<map>
#include<set>
#include<complex>
#include<bitset>
#include<stack>
#include<unordered_map>
#include<utility>
using namespace std;
typedef long long ll;
typedef unsigned int ui;
const ll mod = 1000000007;
typedef long double ld;
const unsinged long long INF = 4e+18;
typedef pair<int, int> P;
#define stop char nyaa;cin>>nyaa;
#define rep(i,n) for(int i=0;i<n;i++)
#define per(i,n) for(int i=n-1;i>=0;i--)
#define Rep(i,sta,n) for(int i=sta;i<n;i++)
#define rep1(i,n) for(int i=1;i<=n;i++)
#define per1(i,n) for(int i=n;i>=1;i--)
#define Rep1(i,sta,n) for(int i=sta;i<=n;i++)
typedef complex<ld> Point;
const ld eps = 1e-8;
const ld pi = acos(-1.0);
typedef pair<ld, ld> LDP;
typedef pair<ll, ll> LP;
#define fr first
#define sc second
#define all(c) c.begin(),c.end()
#define pb push_back
#define int long long

void Yes(){
	cout<<"Yes"<<endl;
	exit(0);
}
 
void No(){
	cout<<"No"<<endl;
	exit(0);
}

signed main() {
	ios::sync_with_stdio(false);
	cin.tie(0);
    int N, K; cin >> N >> K;
    int x[55], y[55];
    vector<int> xs, ys;
    rep(i, N) {
        cin >> x[i] >> y[i];
        xs.pb(x[i]);
        ys.pb(y[i]);
    }
    sort(all(xs));
    sort(all(ys));
    map<int, int> mpx, mpy;
    rep(i, N) {
        mpx[xs[i]] = i;
        mpy[ys[i]] = i;
    }
    int res[55][55];
    memset(res, 0, sizeof(res));
    rep(i, N) {
        res[mpx[x[i]]][mpy[y[i]]] ++;
    }
    int cnt[55][55];
    memset(cnt, 0, sizeof(cnt));
    rep(i, N) {
        rep(j, N) {
            cnt[i + 1][j + 1] = cnt[i][j + 1] + cnt[i + 1][j] - cnt[i][j] + res[i][j];
        }
    }
    unsinged long long ans = INF;
    rep(xmin, N) {
        Rep(xmax, xmin + 1, N) {
            rep(ymin, N) {
                Rep(ymax, ymin + 1, N) {
                    unsinged long long ret = (unsinged long long)(xs[xmax] - xs[xmin]) * (ys[ymax] - ys[ymin]);
                    if(cnt[xmax + 1][ymax + 1] - cnt[xmin][ymax + 1] - cnt[xmax + 1][ymin] + cnt[xmin][ymin] >= K) {
                        ans = min(ans, ret);
                    }
                }
            }
        }
    }
    cout << ans << endl;
	return 0;
}

Compiler output:
a.cc:25:7: error: 'unsinged' does not name a type; did you mean 'unsigned'?
   25 | const unsinged long long INF = 4e+18;
      |       ^~~~~~~~
      |       unsigned
a.cc: In function 'int main()':
a.cc:85:5: error: 'unsinged' was not declared in this scope; did you mean 'unsigned'?
   85 |     unsinged long long ans = INF;
      |     ^~~~~~~~
      |     unsigned
a.cc:90:29: error: expected ';' before 'long'
   90 |                     unsinged long long ret = (unsinged long long)(xs[xmax] - xs[xmin]) * (ys[ymax] - ys[ymin]);
      |                             ^~~~~
      |                             ;
a.cc:92:25: error: 'ans' was not declared in this scope; did you mean 'abs'?
   92 |                         ans = min(ans, ret);
      |                         ^~~
      |                         abs
a.cc:92:40: error: 'ret' was not declared in this scope; did you mean 'res'?
   92 |                         ans = min(ans, ret);
      |                                        ^~~
      |                                        res
a.cc:98:13: error: 'ans' was not declared in this scope; did you mean 'abs'?
   98 |     cout << ans << endl;
      |             ^~~
      |             abs