CF1750D 每日一题 Count GCD
You are given two integers n
and m
and an array a
of n
integers. For each 1≤i≤n
it holds that 1≤ai≤m
.
Your task is to count the number of different arrays b
of length n
such that:
1≤bi≤m
for each 1≤i≤n
, and
gcd(b1,b2,b3,...,bi)=ai
for each 1≤i
原创
2023-01-31 13:20:36 ·
91 阅读 ·
0 评论