#include<iostream>
using namespace std;
int main()
{
for(int i=1; i<=10; i++)
{
for(int j=1; j<=10; j++)
{
cout<< i*j << " ";
if (j*i < 10) // if the number has only one digit
cout<<" "; // then add 1 space after the number
}
cout<<endl;
}
return 0;
}