SEAKAM - Editorial

Oops, Didnt know that, sorry.

Editorialist solution now available.

I solved by the combination of bitmask , dfs , inclusion-exclusion principle ;
Subtask1 got accepted , while as for the remaining , it is giving wrong answer .

below is the link of the solution ; could some point out the bug in the code ?

https://www.codechef.com/viewsolution/9131639

@mukul_chandel
@animan123
@rushilpaul
Hello, I still didnt not understand this solution, Can anyone please explain it in more detail ? That would be really really great.

Please explain the 2 formulae you get, I am familiar with only basic inclusion exclusion of finding the union if intersection and individual cardinality are given.

Thanks in advance.

Link to my ACed Solution : https://www.codechef.com/viewsolution/9159389

1 Like

can anyone give me a link about inclusion exclusion technique.
thanks in advance !!

Hi Guys!

Here is a video editorial on the problem:

[DP With BitMasks - SEAKAM][1]

Cheers!
[1]: https://youtu.be/bjucBkxrMBs

1 Like