#include <iostream>

int main() {
    int sum = 0;
    int num;
    std::cin >> num;
    if (num < 0) {
        std::cout << "You are a bad person!\n";
        return 0;
    }
    while (num != 0) {
        int digit = num % 10;
        num /= 10;
        sum += digit;
    }
    std::cout << sum << '\n';
}
