Program HOC24;
var a: array[1..5] of integer;
t: longint;
i,n: integer;
begin
t:=0;
for i:=1 to n do
begin
write('a[',i,']='); readln(a[i]);
t:=t+a[i];
end;
write('Cac phan tu co gia tri chan : ');
for i:=1 to n do if a[i] mod 2=0 then write(a[i],' ');
writeln;
write('Tông cua mang vua nhap la : ',t);
readln
end.