Codeforces 475D 题解(二分查找+ST表)
题面:
Given a sequence of integers a1, …, an and q queries x1, …, xq on it. For each query xi you have to count the number of pairs (l, r) such that 1 ≤ l ≤ r ≤ n and gcd(al, al + 1, …, ar) = xi.
题目大意...
原创
2018-05-21 13:05:47 ·
480 阅读 ·
0 评论