#include #include using namespace std; int main(){ string s; cin >> s; int64_t ans=0; for(auto c:s) ans += c-'0'; cout << ans << "\n"; return 0; }