Var text:string; i,k:byte; s:char; Begin s:=' '; k:=1; ReadLn(text); For i:=1 to length(text) do If text[i]=s then k:=k+1; Writeln(k); End.
Яндекс