|
more than 450 programs for free
|
![]() English |
![]() Slovensky |
![]() Česky |
![]() Šarišsky |
|
Category: Homework in Pascal Author: Pheo web: pascalsource.ic.cz Program: Count_space.pas File exe: Count_space.exe need: K_pr4.txt Program counting space in text file k_pr4.txt.
Views: 597x
{ COUNT_SPACE.PAS Copyright (c) Pheo } { Program spočíta medzery v texte uloenom v textovom súbore. } { } { Datum:05.04.2005 http://www.trsek.com } program count_space; var t:text; c:char; pocet:integer; begin assign(t,'k_pr4.txt'); reset(t); pocet:=0; while not eof(t) do begin read(t,c); if c=' ' then pocet:=pocet+1 end; writeln('Pocet medzier v subore ',pocet); readln; end. [Run] [Save] [Print] [Send e-mail] |
|