- List ์์ ๊ฐ์ ์ฐพ์ผ๋ ค๋ฉด index() method๋ฅผ ์ฌ์ฉํด์ผ ํ๋ฉฐ
๋๊ฐ์ list๋ฅผ ๋ง๋ค๊ณ index๋ฅผ ์ฌ์ฉํด์ element ๋ผ๋ฆฌ ์ฐ๊ฒฐํด์ ๊ฐ์ ์ฐพ์๋ด์ผ ํ๊ธฐ ๋๋ฌธ์ ํธ๋ฆฌํ์ง ์๊ณ ์ง๊ด์ ์ด์ง๋ ์์.

- ์ด๋ด๋ dictionary๋ฅผ ์ฌ์ฉํ๋ฉด ๋งค์ฐ ํจ๊ณผ์ ์ด๋ค.
- dictionary๋ { key : value } ํํ๋ก ์์ ์ง์ด์ ๊ฐ์ด ๋ค์ด๊ฐ๋ ํํ์ด๋ฉฐ
๊ฐ์ ๋ถ๋ฌ์ฌ๋๋ ๋ถ๋ฌ์ค๊ณ ์ ํ๋ value์ key ๊ฐ์ [] ์์ ์ ์ด์ฃผ๋ฉด ๋๋ค.

- ์ฐ์ต
- dictionary ์ key ๋ค์ ํ์ธํ๊ณ ์ถ์ผ๋ฉด .keys() ์ฌ์ฉํด์ฃผ๋ฉด ๋๋ค. ์๋์ ๊ฐ์ด key์ ๊ฐ์ ๋ฌถ์ด ๋ list ํ์์ผ๋ก ์ถ๋ ฅ๋๋ค.
- value๊ฐ ํ๋๋ฅผ ํ์ธํ๊ณ ์ถ์ผ๋ฉด ํด๋นํ๋ key ๊ฐ์ [] ์์ ๋ฃ์ด์ค๋ค.

- ์ฌ๋ผ์ด๋ ์ถ์ฒ : Datacamp - Datascientist with python
https://campus.datacamp.com/courses/intermediate-python/dictionaries-pandas?ex=5
'๐ฉ๐ปโ๐ป DataScientist for Python > DataCamp' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
| Intermediate Python 6 - Pandas read csv file (0) | 2022.09.20 |
|---|---|
| Intermediate Python 5 - List / Dictionary (1) | 2022.09.20 |
| Intermediate Python 3 - Scatter plot option (0) | 2022.09.19 |
| Intermediate Python 2 - Matplotlib(Ticks) (1) | 2022.09.19 |
| Intermediate Python 1 - Matplotlib (line plot, scatter plot, histogram) (0) | 2022.09.17 |