#include <iostream>
using namespace std;
void main()
{
const int n=100000;
int x[n],i;
for (int i=0; i<=n-2; i++)
{
if x[i]<= x[i+1];
cout<< "1";
}
else
cout<<"0";
system ("pause");
}
The code doesn't seem to work. It says illegal else without if !!! As well as the syntax error for the identifier 'x'. Can anyone plz tell me where are the mistakes?
Comments
Leave a comment