#t336. digit 函数

digit 函数

Background

Special for beginners, ^_^

digit Function

Problem Description

Define a function digit(n,k)digit(n, k) in the program that extracts the kk-th digit of the integer nn counting from the right.

Input Format

A positive integer nn and an integer kk.

Output Format

The value of digit(n,k)digit(n, k).

Sample Input

31859 3

Sample Output

8

Constraints

1s, 1024KiB for each test case.