,


k = 1 N 렠 for k = 1 to N
i := L(k) i = L(k)
(tv(i),c(i),p(i)) ? tv$(i);c(i);p(i)
렠 next k
return
, x[l:N], L[1:N] :
໠ sortmas: '
'
k = 1 N-1 렠 for k = 1 to N-1
xmn := x(k) xmn = x(k)
imn := k imn = k
i = k + 1 N 렠 for i = k + 1 to N
x(i) < xmn  if x(i) < xmn then
xmn := x(i) xmn = x(i)
imn := i imn = i
蠠 end if
렠 next i
Imn := L(imn) Imn = L(imn)
xmn := x(imn) xmn = x(imn)
L(imn) := L(k) L(imn) = L(k)
x(imn) := x(k) x(imn) = x(k)
L(k) :=Imn L(k) = Imn