Sözlükler, Bölüm 1

Orta Seviye Python

Hugo Bowne-Anderson

Data Scientist at DataCamp

Liste

pop = [30.55, 2.77, 39.21]

countries = ["afghanistan", "albania", "algeria"]
ind_alb = countries.index("albania")
ind_alb
1
pop[ind_alb]
2.77
  • Kullanışlı değil
  • Sezgisel değil
Orta Seviye Python

Sözlük

pop = [30.55, 2.77, 39.21]

countries = ["afghanistan", "albania", "algeria"] ...
{ }
Orta Seviye Python

Sözlük

pop = [30.55, 2.77, 39.21]

countries = ["afghanistan", "albania", "algeria"] ...
{"afghanistan":30.55, }
Orta Seviye Python

Sözlük

pop = [30.55, 2.77, 39.21]

countries = ["afghanistan", "albania", "algeria"] ...
world = {"afghanistan":30.55, "albania":2.77, "algeria":39.21}
world["albania"]
2.77
Orta Seviye Python

Hadi pratik yapalım!

Orta Seviye Python

Preparing Video For Download...