#include int main(void) { char s[101]; int i = 0; int count = 0; scanf("%s", s); while(s[i] != 0){ if(s[i] != '0'){ count++; } i++; } printf("%d\n", count - 1); return 0; }