marcose18's blog

By marcose18, 7 years ago, In English

Can someone please explain how to solve the problem http://codeforces.com/problemset/problem/453/B I am unable to understand even the editorials here http://codeforces.com/blog/entry/13190 that how not taking the factors of given array a[i] will minimise the expression like in editorials and operation is done to remove the prime factors of a[i] using bitmask.Also I wasn;t able to understand the dp part.So a detailed explanation will be highly appreciated. Thanks in advance.

 
 
 
 
  • Vote: I like it
  • +2
  • Vote: I do not like it

»
7 years ago, # |
  Vote: I like it 0 Vote: I do not like it

a person who know bitmasks & dp well can undrestand the solotion whit this hints... i think you nedd to know more of Dp ans Bitmask :D