here is the solution to my code.
#include
using namespace std;
int main()
{
int i,n,j;
cout<<βEnter the range:β;
cin>>n;
cout<<β1β<<endl;;
for(i=2;i<=n;i++){
cout<<β1β;
for(j=1;j<=i-2;j++){
cout<<β0β;
}
cout<<"1"<<"\n";
}
return 0;
}