Note: There is no official syllabus for ZCO vs INOI vs IOITC. Syllabus for ZCO, INOI has been determined by looking at all the concepts covered in all ZCO, INOI problems since last 5 years. All the topics covered by ZCO, INOI are also in the Basic topics section of ICO online study material. Syllabus for IOITC is same as syllabus for IOI, since the training camp is training you for IOI. There is a higher focus on the topics mentioned in the Advanced topics specifically covered in ICO online study material. :)
The below tutorials are the best tutorials on the internet for each topic. If you find better tutorials for a particular topic, please share them with everyone.
Now I get it, I was misinterpreting question all this time. Actually after finish of each round, lead is not the difference between points of that round. But the lead is difference between the points achieved through all rounds including current round - Lakpa Tashi Bhutia
I made a DP state similar to LCS where dp[i][j] indicates the length of the best subsequence possible using A[0..j] and B[0..j]. Then for each state I select an element from A[0..j-1] and try to find its complement in B using a map. See the code for more detail.
However this fails on all test cases except two giving me a depressing 20/100.
What is wrong with my DP? What other approaches are possible? This approach (if you assume all elements in B are distinct) becomes O(N^3 log N). If we don't assume all elements are distinct, we get ~= the same time (I guess?). I did not get any TLEs on the judge, and the worst time was 0.103s so that's a good sign.