#include<bits/stdc++.h>
using namespace std;
int main()
{
int t, n, f = 0;
cin >> t;
while(t--)
{
cin >> n;
if(n >= 0 && n <= 10)
cout << 0 << " " << n << "\n";
else if(n >=11 && n <= 19)
cout << n%10 << " " << n - (n%10) << "\n";
else if(n == 20)
cout << 10 << " " << 10 << "\n";
}
return 0;
}
using namespace std;
int main()
{
int t, n, f = 0;
cin >> t;
while(t--)
{
cin >> n;
if(n >= 0 && n <= 10)
cout << 0 << " " << n << "\n";
else if(n >=11 && n <= 19)
cout << n%10 << " " << n - (n%10) << "\n";
else if(n == 20)
cout << 10 << " " << 10 << "\n";
}
return 0;
}
Comments
Post a Comment