My solutions was accepted by interview street.
Firstly, my solutions wasn’t accepted, but after saw @Reinardus Surya Pradhit post, i realized, if pair (x, y) will be count twice, so i change it a litter bit and got success
I will not post my solution here, but i can tell you the test case for all variable from N = 3 -> N = 10
Here the result
N=3: 9
N=4: 21
N=5: 63
N=6: 135
N=7: 405
N=8: 675
N=9: 1215
N=10: 2295
My hint is: try to express N! in primes from like p1^q1 * p2^q2 * ... * pn^qn
1
solved Sample testcase for Interviewstreet: Equations