题意:k^D=n(%p),求最小的D (1<=K, P, N<=10^9)
思路:出题人英文水平捉鸡。。。。
Description # 已知数a,p,b,求满足a^x≡b(mod p)的最小自然数x。
离散对数(Discrete Logarithm)问题是这样一个问题,它是对于模方程
题目链接
题意:
Given a prime P, 2 <= P < 231, an integer B, 2 <= B < P, and an integer N, 1 <= N < P, compute the discrete logarithm of N, base B, modulo P. That is, find an integer L such that BL == N (mod P)