import std.stdio, std.string, std.conv, std.range, std.array, std.algorithm;
import std.uni, std.math, std.container, std.typecons, std.typetuple;
import core.bitop, std.datetime;
 
void main()
{
    int n;
    long k;
    readVars(n, k);

    auto bkt = new long[](10^^5 + 1);

    int ai, bi;

    foreach(i ; 0 .. n){
        readVars(ai, bi);
        bkt[ai] += bi;
    }

    long cnt;

    foreach(i ; 1 .. 10^^5 + 1) {
        cnt += bkt[i];

        if (cnt >= k) {
            writeln(i);
            return;
        }
    }
}
 
void readVars(T...)(auto ref T args){
    auto line = readln.split;
    foreach(ref arg ; args){
        arg = line.front.to!(typeof(arg));
        line.popFront;
    }
    if(!line.empty){
        throw new Exception("args num < input num");
    }
}