Problem link : https://codeforces.com/problemset/problem/1966/B
I am not able to solve this problem. Can anyone help me?
Try:
I tried to do brute force for all squares with a time complexity of O(n^4).
I am expecting an optimized code. Can anyone please provide code with concept.
New contributor
Math ROCKER is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.