// Slower C++ solution:
#include <iostream>

#include <cstdio>

#include <algorithm>

using namespace std;

typedef long long ll;

typedef double db;

const int N = 200010;

ll a[N],b[N],k,x,s; // a b=-a

int n;

int les(ll* arr,int L,int R,ll y) {

    int M,B=-1;

    while(L<=R) {

        M=(L+R)>>1;

        if(arr[M]<y) B=M,L=M+1;

        else R=M-1;

    }

    return B;

}

int lar(ll *arr,int L,int R,ll y) {

    int M,B=-1;

    while(L<=R) {

        M=(L+R)>>1;

        if(arr[M]>y) B=M,R=M-1;

        else L=M+1;

    }

    return B;

}

ll ceild(ll a,ll b){

    if(a%b==0||a<0&&b>0||a>0&&b<0) return a/b;

    return a/b+1;

}

ll floord(ll a,ll b){

    if(a%b==0||a>0&&b>0||a<0&&b<0) return a/b; 

    return a/b-1;

}

int check(ll val) {

    ll ls=0,lr=0,eq;

    int tmp;

    // cout<<ls<<" "<<lr<<endl;

    for(int i=1;i<=n;i++) {

        // printf("a[%d]=%lld\n",i,a[i]);

        if(a[i]>0){

            tmp=les(a,i+1,n,ceild(val,a[i]));

            if(tmp!=-1) ls+=(ll)(tmp-i);

            // printf("+less tmp : %d ls:%d\n",tmp,ls);

            tmp=lar(a,i+1,n,floord(val,a[i]));

            if(tmp!=-1) lr+=(ll)(n-tmp+1);

            // printf("+large tmp : %d lr:%d\n",tmp,lr);

        }

        else if(a[i]<0){

            tmp=lar(a,i+1,n,floord(val,a[i]));

            if(tmp!=-1) ls+=(ll)(n-tmp+1);

            // printf("-less tmp : %d ls:%d\n",tmp,ls);

            tmp=les(a,i+1,n,ceild(val,a[i]));

            if(tmp!=-1) lr+=(ll)(tmp-i);

            // printf("-large tmp : %d lr:%d\n",tmp,lr);

        }

        else {

            if(val>0)ls+=(ll)(n-i);

            if(val<0)lr+=(ll)(n-i);

        }

    }

    eq=s-lr;

    // cout<<ls<<" _ "<<eq<<" _ "<<lr<<endl;

    if(k<=ls) return 1;// less

    if(k<=eq) return 2;// eq

    return 3;//large

}

int main() {

    scanf("%d%lld",&n,&k);

    s=(n-1ll)*n/2ll;

    for(int i=1;i<=n;i++) {

        scanf("%lld",&x);

        a[i]=x;

    }

    sort(a+1,a+n+1);

    ll L=-1e18,R=1e18,M,ans;

    while(L<=R) {

        M=(L+R)>>1;

        int d=check(M);

        // cout<<L<<" "<<R<<" "<<M<<" "<<d<<endl;

        if(d==2) {ans=M;break;}

        else if(d==1) R=M-1;

        else L=M+1,ans=M;

        // system("pause");

    }

    printf("%lld\n",ans);

}

// Faster C++ solution for the same problem (measured speedup: 4.846508346551629x):
#include <cstdio>

#include <algorithm>

#define ll long long

using namespace std;

const ll inf=1e18+10;

ll n,k,ans,a[200005];

ll find1(int now,ll x){

	int l=now+1,r=n,best=now;

	while(l<=r){

		int mid=l+r>>1;

		if(a[now]*a[mid]<=x){

			l=mid+1;

			best=mid;

		}

		else r=mid-1;

	}

	return best;

}

ll find2(int now,ll x){

	int l=now+1,r=n,best=n+1;

	while(l<=r){

		int mid=l+r>>1;

		if(a[now]*a[mid]<=x){

			r=mid-1;

			best=mid;

		}

		else l=mid+1;

	}

	return best;

}

bool check(ll x){

	ll cnt=0;   //找比 x 小的积 

	for(int i=1;i<n;i++){

		if(a[i]>=0) cnt+=find1(i,x)-i;

		else cnt+=n-find2(i,x)+1;

	}

	return cnt>=k;

}

int main(){

	scanf("%lld%lld",&n,&k);

	for(int i=1;i<=n;i++) scanf("%lld",&a[i]);

	sort(a+1,a+n+1);

	ll l=-inf,r=inf;

	while(l<=r){

		ll mid=l+r>>1;

		if(check(mid)){

			ans=mid;

			r=mid-1;

		}

		else l=mid+1;

	}

	printf("%lld",ans);

	return 0;

}