k-th Prime Factor


Submit solution

Points: 100
Time limit: 1.0s
Memory limit: 256M

Author:
Problem types

Prime factors are ordered non-decreasingly and repeated according to multiplicity. Find the \(k\)-th factor of \(n\).

Input

One line containing \(n\) and \(k\).

The input satisfies:

  • \(1 \le n, k \le 10^9\)

Output

Print the requested factor, or -1 if fewer than \(k\) factors exist.

Example

Input
633899 1
Output
7

Comments

There are no comments at the moment.