Hi,
I know discussing anything related to an ongoing contest isn’t acceptable. I have already solved the problem but I have a doubt related to constraint and online judge.
https://www.codechef.com/JUNE21C/problems/CHFHEIST
In problem bella ciao - june long challenge, the constraint mentioned in the problem for D,d,P,Q is in between 1 - 10^6. I wrote a cpp code and used int data type for these inputs, this gave me WA and when I used long then AC. Why?
In c++, int range is in between -2x10^9 to 2x10^9.
I hope, this post doesn’t violate any rules and I didn’t reveal anything related to the solution.
Thanks