Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- program sucetparnych;
- {$APPTYPE CONSOLE}
- uses SysUtils;
- var n,i,c,pc,v:byte;
- begin
- { TODO -oUser -cConsole Main : Insert code here }
- write('Kolko cisiel chcete zadat?: ');
- readln(n);
- v:=0;
- pc:=0;
- for i:=1 to n do
- begin
- write('Zadajte cislo: ');
- readln(c);
- if c mod 2 = 0 then
- begin
- pc:=c;
- v:=v+pc;
- end;
- end;
- writeln('Vysledok: ',v);
- readln;
- end.
Advertisement
Add Comment
Please, Sign In to add comment