东方博宜 1962. 数值计算
#include<iostream>
using namespace std;
int main()
{
int n ;
cin >> n ;
int cnt = 0 ;
int a[6] ;
int k = 0 ;
while(true)
{
a[k] = n % 10 ;
k++ ;
cnt += 1 ;
n = n/10;
if(n==0)
break;
}
cout << cnt << endl ;
for(int i = cnt-1 ; i >= 0 ; i--)
cout << a[i] << " " ;
cout << endl ;
for(int j = 0 ; j < cnt ; j++)
cout << a[j] ;
}