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
affd77f7
Kaydet (Commit)
affd77f7
authored
Tem 16, 1998
tarafından
Guido van Rossum
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Add tests for list self-assigns. (Sorry, this should have been here
before JPython 1.0 came out.)
üst
0fd00334
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
test_types.py
Lib/test/test_types.py
+13
-0
No files found.
Lib/test/test_types.py
Dosyayı görüntüle @
affd77f7
...
...
@@ -134,6 +134,19 @@ if 0*[1,2,3] <> []: raise TestFailed, 'list repetition 0*'
if
min
([
1
,
2
])
<>
1
or
max
([
1
,
2
])
<>
2
:
raise
TestFailed
,
'min/max list'
if
0
in
[
0
,
1
,
2
]
and
1
in
[
0
,
1
,
2
]
and
2
in
[
0
,
1
,
2
]
and
3
not
in
[
0
,
1
,
2
]:
pass
else
:
raise
TestFailed
,
'in/not in list'
a
=
[
1
,
2
,
3
,
4
,
5
]
a
[:
-
1
]
=
a
if
a
!=
[
1
,
2
,
3
,
4
,
5
,
5
]:
raise
TestFailed
,
"list self-slice-assign (head)"
a
=
[
1
,
2
,
3
,
4
,
5
]
a
[
1
:]
=
a
if
a
!=
[
1
,
1
,
2
,
3
,
4
,
5
]:
raise
TestFailed
,
"list self-slice-assign (tail)"
a
=
[
1
,
2
,
3
,
4
,
5
]
a
[
1
:
-
1
]
=
a
if
a
!=
[
1
,
1
,
2
,
3
,
4
,
5
,
5
]:
raise
TestFailed
,
"list self-slice-assign (center)"
print
'6.5.3a Additional list operations'
a
=
[
0
,
1
,
2
,
3
,
4
]
...
...
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