olahiuj的博客

想要再努力一点

51nod1203 JZPLCM rmq+莫队

Description 长度为N的正整数序列S,有Q次询问,每次询问一段区间内所有数的lcm(即最小公倍数)。由于答案可能很大,输出答案Mod 10^9 + 7。 例如:2 3 4 5,询问[1,3]区间的最小公倍数为2 3 4的最小公倍数 = 12。 2 <= N...

2018-07-22 13:32:27

阅读数:26

评论数:0

Frequent values_poj3368_rmq

DescriptionYou are given a sequence of n integers a1 , a2 , … , an in non-decreasing order. In addition to that, you are given several queries consis...

2016-09-24 16:43:43

阅读数:221

评论数:0

Balanced Lineup_poj3264_rmq ST

DescriptionFor the daily milking, Farmer John’s N cows (1 ≤ N ≤ 50,000) always line up in the same order. One day Farmer John decides to organize a g...

2016-09-22 17:33:50

阅读数:251

评论数:0

提示
确定要删除当前文章?
取消 删除
关闭
关闭