//Himanshu Shukla
#pragma GCC optimize("O2")
#include <bits/stdc++.h>
using namespace std;
#define FASTIO ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0)
//#define file_input
//#define multitest
//#define measure_time
#define ll long long
#define v32 vector<int>
#define v64 vector<ll>
#define s32 set<int>
#define s64 set<ll>
#define graph vector<v32>
#define p32 pair<int, int>
#define p64 pair<ll, ll>
#define sz(v) (ll)(v).size()
#define fi first
#define se second
#define ln '\n'
#define debug(x) cerr << (#x) << ": " << (x) << ln
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
inline ll add(ll a, ll b, ll m) { return (((a % m + b % m) % m + m) % m); }
inline ll mul(ll a, ll b, ll m) { return (((a % m * b % m) % m + m) % m); }
const double EPS = 1e-6;
const ll MOD = 1e9 + 7;
template <typename T, typename U>
ostream &operator<<(ostream &out, const pair<T, U> &p)
{
	out << '[' << p.fi << ", " << p.se << ']';
	return out;
}
template <template <typename, typename...> class ContainerType, typename ValueType, typename... Args>
void print_container(const ContainerType<ValueType, Args...> &c)
{
	cout << "{ ";
	for (const auto &v : c)
		cout << v << ' ';
	cout << '}' << ln;
}

const int N = 2e5 + 5;
ll n, k, arr[N], zero;
v64 pos, neg;

bool check_zero(ll x)
{
	ll cnt = zero * (zero - 1) / 2 + zero * sz(neg) + zero * sz(pos) + sz(neg) * sz(pos);
	return (cnt >= k);
}

bool check_pos(ll x)
{
	ll cnt = zero * (zero - 1) / 2 + zero * sz(neg) + zero * sz(pos) + sz(neg) * sz(pos);
	for (int i = 0; i < sz(neg) - 1; i++)
	{
		int idx = lower_bound(neg.begin() + i + 1, neg.end(), x / neg[i] + 1) - neg.begin();
		idx--;
		cnt += (idx - i);
	}
	for (int i = 0; i < sz(pos) - 1; i++)
	{
		int idx = lower_bound(pos.begin() + i + 1, pos.end(), x / pos[i] + 1) - pos.begin();
		idx--;
		cnt += (idx - i);
	}
	return (cnt >= k);
}

bool check_neg(ll x)
{
	ll cnt = 0;
	x = -x;
	for (int i = 0; i < sz(neg); i++)
	{
		ll key = (x + neg[i] - 1) / neg[i];
		int idx = lower_bound(pos.begin(), pos.end(), key) - pos.begin();
		cnt += (sz(pos) - idx);
	}
	return (cnt >= k);
}

bool check(ll x)
{
	if (x == 0)
		return check_zero(x);
	else if (x > 0)
		return check_pos(x);
	else
		return check_neg(x);
}

void solve()
{
	cin >> n >> k;
	for (int i = 0; i < n; i++)
	{
		cin >> arr[i];
		if (arr[i])
		{
			if (arr[i] < 0)
				neg.push_back(-arr[i]);
			else
				pos.push_back(arr[i]);
		}
		else
			zero++;
	}
	//debug(zero);
	sort(neg.begin(), neg.end());
	sort(pos.begin(), pos.end());
	ll lo = -1e18, hi = 1e18, ans = -1e8;
	while (hi - lo > 1)
	{
		ll mid = (hi + lo) / 2;
		if (check(mid))
			ans = hi = mid;
		else
			lo = mid;
		//debug(lo);
		//debug(hi);
	}
	cout << ans << ln;
	return;
}

int main()
{
	FASTIO;
#ifdef file_input
	freopen("input.txt", "r", stdin);
	freopen("output.txt", "w", stdout);
#endif
	clock_t start, stop;
	int t = 1;
#ifdef multitest
	cin >> t;
#endif
#ifdef measure_time
	start = clock();
#endif
	for (int tc = 1; tc < t + 1; tc++)
		solve();
#ifdef measure_time
	stop = clock();
	cerr << "Time :" << fixed << setprecision(5) << double(stop - start) / double(CLOCKS_PER_SEC) << "s" << ln;
#endif
	return 0;
}


Measured memory_bytes: 3572