program C1;
uses crt;
Var A:array[1..100] of Integer ;
Tc, Tl : Integer ;
n, i: Btybe ;
begin
clrscr ;
Write( ' nhap n: ' ) ; Readln(n) ;
For i:=1 to n do
begin
Write ( ' A[ ' ,i, '] = ' ) ; Readln (A[i]) ;
end ;
Tc: = 0 ; Tl: = 0 ;
For i: = 1 to n do
If A[i] mod 2=0 then Tc:=Tc+A[i]
else Tl:= Tl + A[i] ;
Writeln ( ' Tong so chan : ' ; Tc) ;
Writeln ( ' Tong so le : ' , Tl ) ;
readln ;
end.