#include #include #include using namespace std; char c1, c2, n[100]; int main() { while(true) { cin>>n>>c1>>c2; if (n[0]=='0' and c1=='0' and c2=='0') break; for(int i=0; i