What is wrong with the code

#include
using namespace std;
int main() {
int t;
cin>>t;
while(t–)
{
long long int n;
cin>>n;
int arr[n];
for(int i=0;i<n;i++)
{
cin>>arr[i];
}
int inc[n],dec[n];
inc[0]=1;
dec[n-1]=1;
for(int i=1;i<n;i++)
{
if(arr[i]>=arr[i-1])
{
inc[i]=inc[i-1]+1;
}
else
{
inc[i]=1;
}
}
for(int i=n-2;i>=0;i–)
{
if(arr[i]>=arr[i+1])
{
dec[i]=dec[i+1]+1;
}
else{
dec[i]=1;
}
}
int max=inc[0]+dec[0]-1;
for(int i=1;i<n;i++)
{
if(inc[i]+dec[i]-1 > max)
max=inc[i]+dec[i]-1;
}
cout<<max<<endl;
}
return 0;
}

your code https://ide.codingblocks.com/s/245932 is passing all the test cases, can you please tell the problem you are facing i.e WA, TLE. Runtime Error.

can you plz explain me what is the use of the two lines u added

cin is slow in taking input, those 2 lines makes it faster

@kunakgoyal your doubt has been already resolved please mark it resolved and rate it