#include<stdio.h>
#include<string.h>
int main()
{
    char sentance[100];
    int i=0;
    int length=0;
    fgets(sentance,sizeof(sentance),stdin);
    sentance[strcspn(sentance ,"\n")]='\0'
    i=strlen(sentance) - 1;
    while(i>=0&& sentance =='')
    {
        i--;
    }
    while(i>=0 && sentance != '')
    {
        length++;
        i--;
    }
    printf("%d",length);
    return 0;
}