I have submitted two codes earlier for the problem Priya and And - CENS20D,

## this code got WA

```
for(int i=0;i<n;i++) {
for(int j=i+1;j<n;j++) {
if(a[i]&a[j]==a[i]) ans++;
}
}
```

## this code got AC

```
for(int i=0;i<n;i++) {
for(int j=0;j<n;j++) {
if((a[i]&a[j])==a[i] and i<j) ans++;
}
}
```

please check the links to the WA code and the AC code .

Thanks in advance