eolymp
bolt
Try our new interface for solving problems
Məsələlər

Power of Cryptography

Power of Cryptography

Zaman məhdudiyyəti 1 saniyə
Yaddaşı istafadə məhdudiyyəti 122 MiB

Given an integer n1 and an integer p1 you are to write a program that determines , the positive n-th root of p. There always exists such integer k that k^n^{ }= p.

Giriş verilənləri

Consists of two numbers n and p (1n300, 1p10^100). It is known that there always exists an integer k (1k10^9) such that k^n = p.

Çıxış verilənləri

Print the value , i.e. the number k such that k^n = p.

Nümunə

Giriş verilənləri #1
2 16
Çıxış verilənləri #1
4
Giriş verilənləri #2
3 27
Çıxış verilənləri #2
3
Giriş verilənləri #3
7 4357186184021382204544
Çıxış verilənləri #3
1234