A mafia has infiltrated the city <insert name here>. This has made the police force of <insert name here> very confused, with accusations of corruption being made in every direction. The city's N cops (which are numbered between 0 and N−1) has made a number of accusations about other policemen. Each accusation is either:
An honest cop always tells the truth, while a corrupt cop always lies. In total, there has been M accusations.
The chief of police is now trying to fix the situation, starting with determining how many of her police men are corrupt. She has G different guesses about the number of corrupt cops, and for each such number C, she wants to know how many different sets of size C can be corrupt (where all the remaining cops are honest), given that all accusations are consistent.
The sample judge reads input in the following format:
N MA[0] ... A[M - 1]B[0] ... B[M - 1]T[0] ... T[M - 1]G: the number of calls made to guess(C).C1 ... CG: the parameters of the G calls to guess(C).The sample judge will write G lines with the return values of guess(C).
Let G be the number of calls to guess(C).