var n: integer;
begin
read(n);
write(n div 100 + n div 10 mod 10 + n mod 10)
end.
#include <bits/stdc++.h>
#include <string>
int main(){
string s;
cin >> s;
int sum = 0, null = 1;
for(auto f: s){
sum += f - '0';
null *= f - '0';
}
cout << null % sum << '\n';
swap(s[1], s[2]);
cout << s;
return 0;
var n: integer;
begin
read(n);
write(n div 100 + n div 10 mod 10 + n mod 10)
end.
#include <bits/stdc++.h>
#include <string>
int main(){
string s;
cin >> s;
int sum = 0, null = 1;
for(auto f: s){
sum += f - '0';
null *= f - '0';
}
cout << null % sum << '\n';
swap(s[1], s[2]);
cout << s;
return 0;
}