目录 @description@ @solution@ @accepted code@ @details@ @description@ 给定 n, a, b, p,其中 n, a 互质.定义一个长度为 n 的 01 串 c[0..n-1],其中 c[i] == 0 当且仅当 (ai+b) mod n < p. 给定一个长为 m 的小 01 串,求出小串在大串中出现了几次. input 第一行包含整数 n, a, b, p, m (2<=n<=10^9, 1<=p, a, b, m&…
题目链接: http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=2818 题目描述: Given positive integers B and N, find an integer A such that AN is as close as possible to B. (The result A is an approximation to the Nth root of B.) Note that AN may be l…