Program HOC24;
var a: array[1..250] of integer;
i,n: integer;
t: longint;
begin
write('Nhap N: '); readln(N);
t:=0;
for i:=1 to n do if i mod 2=1 then t:=t+i;
write('Tong cac phan tu o vi tri le la: ',t);
readln
end.
uses crt;
var a:array[1..250]of integer;
i,n,t:integer;
begin
clrscr;
write('Nhap n='); readln(n);
for i:=1 to n do
begin
write('A[',i,']='); readln(a[i]);
end;
t:=0;
for i:=1 to n do
if (a[i] mod 2<>0) and (i mod 2=0) then t:=t+a[i];
writeln(t);
readln;
end.