var
a:array[1..100] of integer;
i,j,tg,n:integer;
Begin
readln(n);
for i:=1 to n do
readln(a[i]);
for i:=1 to n-1 do
for j:=i+1 to n do
if a[i]>a[j] then
begin
tg:=a[i];
a[i]:=a[j];
a[j]:=tg;
end;
write('phan tu nho thu 2 la:',a[2]);
readln
End.
var
a:array[1..100] of integer;
i,j,tg,n:integer;
Begin
readln(n);
for i:=1 to n do
readln(a[i]);
for i:=1 to n-1 do
for j:=i+1 to n do
if a[i]>a[j] then
begin
tg:=a[i];
a[i]:=a[j];
a[j]:=tg;
end;
write('phan tu nho thu 2 la:',a[2]);
readln
End.