Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
3ed5c2a2
Kaydet (Commit)
3ed5c2a2
authored
Kas 08, 2006
tarafından
Georg Brandl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Bug #1592533: rename variable in heapq doc example, to avoid shadowing
"sorted". (backport from rev. 52668)
üst
082f14b6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
libheapq.tex
Doc/lib/libheapq.tex
+4
-4
No files found.
Doc/lib/libheapq.tex
Dosyayı görüntüle @
3ed5c2a2
...
@@ -76,14 +76,14 @@ Example of use:
...
@@ -76,14 +76,14 @@ Example of use:
>>> for item in data:
>>> for item in data:
... heappush(heap, item)
... heappush(heap, item)
...
...
>>>
sort
ed = []
>>>
order
ed = []
>>> while heap:
>>> while heap:
...
sort
ed.append(heappop(heap))
...
order
ed.append(heappop(heap))
...
...
>>> print
sort
ed
>>> print
order
ed
[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
>>> data.sort()
>>> data.sort()
>>> print data ==
sort
ed
>>> print data ==
order
ed
True
True
>>>
>>>
\end{verbatim}
\end{verbatim}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment