C ++ program to count number of values that satisfy x ^ 2 = 1 mod p where x lies in range [ 1 , n ]
#include <bits/stdc++.h> NEW_LINE using namespace std ; typedef long long ll ; int findCountOfSolutions ( int n , int p ) {