Main.cc: In function 'int main()': Main.cc:9:17: warning: suggest parentheses around '&&' within '||' [-Wparentheses] if(a[i]==a[i+2]&&i+2