#include <unordered_map>
#include <unordered_set>
#include <algorithm>
#include <iostream>
#include <numeric>
#include <cstring>
#include <cassert>
#include <string>
#include <vector>
#include <queue>
#include <deque>
#include <cmath>
#include <set>
#include <map>

using namespace std;
#define     loop(n,i,a)     for(int i=a;i<n;i++)
#define     all(arr,n)      arr,arr+n
#define     allv(v)         (v).begin(),(v).end()
#define     rallv(v)        (v).rbegin(),(v).rend()
#define     m_p             make_pair
#define     ll              long long
#define     vi              vector<int>
#define     vll             vector<ll>
#define     sz(x)           (int)x.size()
#define     pb              push_back
int dx[] = { -1, -1, -1, 0, 0, 1, 1, 1 };
int dy[] = { -1, 0, 1, -1, 1, -1, 0, 1 };

int main() {
	ll n,k;cin>>n>>k;
	vll v(n);
	loop(n,i,0)cin>>v[i];
	sort(allv(v));
	ll l=-1e18,r=1e18,res=-1;
	while(l<=r){
		ll mid=(l+r)/2,cnt=0;
		loop(n,i,0){
			if(v[i]>0){
			ll li=i+1,ri=n-1,c=i;
			while(li<=ri){
				ll j=(li+ri)/2;
				if(v[i]*v[j]<=mid){
					c=j;
					li=j+1;
				}
				else ri=j-1;
			}
			cnt+=(c-i);
		}
			else{
				ll li=i+1,ri=n-1,c=n;
				while(li<=ri){
					//cout<<li<<' '<<ri<<' '<<mid<<' '<<i<<endl;
					ll j=(li+ri)/2;
					if(v[i]*v[j]<=mid){
						c=j;
						ri=j-1;
					}
					else li=j+1;
				}
				cnt+=(n-c);
			}
		}
			if(cnt>=k){
				res=mid;
				r=mid-1;
			}
			else l=mid+1;
		}
	cout<<res<<endl;
	return 0;
}
