DIVISIBLE SUBARRAYS

whats wrong in my code? i am not getting correct output.
question is :
You are given N elements, a1,a2,a3….aN. Find the number of good sub-arrays.
A good sub-array is a sub-array [ai,ai+1,ai+2….aj] such that (ai+ai+1+ai+2+….+aj) is divisible by N.

Input Format:
The first line contains the number of test cases T. First line of each test case contains an integer N denoting the number of elements. Second line of each test case contains N integers, a1, a2, a3….aN, where ai denotes the ith element of the array.

Constraints:
1<=T<=10 1<=N<=10^5 |ai|<=10^9

Output Format
Output a single integer denoting the number of good sub-arrays.

Sample Input
2
5
1 1 1 1 1
5
5 5 5 5 5

Sample Output
1
15

my code is

#include
#include
#define ll long long
using namespace std;
int main(){
int t;
cin>>t;
while(t>0){
ll n;
cin>>n;
ll arr[n];
ll aux[n];
memset(aux,0,n);
cin>>arr[0];
aux[arr[0]%n]++;
for(ll i=1;i<n;i++){
cin>>arr[i];
arr[i]=arr[i-1]+arr[i];
aux[arr[i]%n]++;

	}
	ll tot=0;
	for(ll i=0;i<n;i++){
		ll curr=0;
		if(aux[i]>1) curr=aux[i]*(aux[i]-1)/2;
		tot+=curr;

	}
	cout<<tot<<endl;

	t--;
}

}