Problem Statement: http://codeforces.com/contest/118/problem/D Approach : Simple memorization . Solution :
Tag: codeforces
Codeforces 489 D: Unbearable Controversy of Being
Codeforces 448 D: Multiplication Table
http://codeforces.com/problemset/problem/448/D How to Solve: https://www.quora.com/How-is-the-following-problem-solvable-using-Binary-Search-Problem-448D-Codeforces Please follow the above link ! Solution :