after thinking from all possible approaches my solution is if n is odd player 1 win and if n is even player 2 win but testcases and are passing editorial is also not available please help
How to approach this problem
For N pile
For m stones each:
Find divisors of m
Let say a1,a2,a3…an
Grundy(m)=Max(Grundy(a1),Grundy(a2),Grundy(a3),…)
Ans=2 if((Grundy(m)==0)||(n%2==0))
else
Ans=1
You shall do all these things in optimized way.