#include <stdio.h> #include <string.h> #include <math.h> const int MAXN = 100; char x[MAXN]; int main() { while (scanf("%s", x)!=EOF) { int ans = 0, j = 0, tail = 1; int length = strlen(x); for (int i = length; i >= 0; i--) { if (x[i] == 0 && tail == 1) continue; else { ...