Please help me know why my code is not passing test cases.Help me

#include
using namespace std;
int main(){
int N;
cin>>N;
int row=1;
if(N>0 && N<=10){
if(row==1){
for(int space=1;space<= N-1;space++){
cout<<" “;
}
cout<<“1”<<endl;
}
for(row=2;row<=N;row++){
for(int space=1;space<=N-row;space++){
cout<<” “;
}
cout<<“1”;
int col = 1;
while(col<=row-2){
int val = row - 1 ;
cout<<” “<<val;
col=col+1;
}
cout<<” "<<“1”<<endl;
}
}
return 0;
}

@shresth_2000 please share your code by saving it on cb ide

now please help me solve the programme

@shresth_2000 please share the code from your computer if you have it, formatting of this code has changed and it is not running at all. Its hard to debug a code without running it and seeing the output

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.