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
2a6e68f6
Kaydet (Commit)
2a6e68f6
authored
Kas 19, 1996
tarafından
Barry Warsaw
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Output original address
üst
de0e8f76
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
world
Tools/world/world
+4
-4
No files found.
Tools/world/world
Dosyayı görüntüle @
2a6e68f6
#! /
usr/
bin/env python
#! /bin/env python
"""Print the long name of an Internet domain.
"""Print the long name of an Internet domain.
...
@@ -43,11 +43,11 @@ def resolve(rawaddr):
...
@@ -43,11 +43,11 @@ def resolve(rawaddr):
return
return
addr
=
parts
[
-
1
]
addr
=
parts
[
-
1
]
if
nameorg
.
has_key
(
addr
):
if
nameorg
.
has_key
(
addr
):
print
addr
,
'is from a USA'
,
nameorg
[
addr
],
'organization'
print
raw
addr
,
'is from a USA'
,
nameorg
[
addr
],
'organization'
elif
country
.
has_key
(
addr
):
elif
country
.
has_key
(
addr
):
print
addr
,
'originated from'
,
country
[
addr
]
print
raw
addr
,
'originated from'
,
country
[
addr
]
else
:
else
:
print
'Where in the world is
%
s?'
%
addr
print
'Where in the world is
%
s?'
%
raw
addr
...
...
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