Please Help me in this code

#include
using namespace std;
int main(){
int n;
cin>>n;
int row=1;
while(row<=n)
{
int col=1;
if(row<=n){
while(col<=row){

       cout<<col;
       col++;
       }
       for(int i=0;i<=n;i++){
           
       
       cout<<"*";
       
       }
       
   }
     cout<<endl;
     row=row+1;

}
return 0;

}

some mistake in your code i have corrected them
check and if have any doubt feel free to ask

Modified Code

thanks for help I understood my mistake

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.