Var n,sum,d,ind,first:integer;
begin
Write('n');
Readln(n);
d:=1;
ind:=0;
sum:=0;
if n div d=0 then
begin
ind:=1;
sum:=n;
end
else
begin
while n div d<>0 do
begin
inc(ind);
sum:=sum+(n div d) mod 10;
d:=d*10;
end;
end;
Writeln('suma',Sum);
Writeln('kolvo',ind);
first:=(n div round(d/10)) mod 10;
writeln('first',first);
readln;
end.