- Day 5
- Lists
- How to Create a List
- Accessing List Items Using Positive Indexing
- Accessing List Items Using Negative Indexing
- Unpacking List Items
- Slicing Items from a List
- Modifying Lists
- Checking Items in a List
- Adding Items to a List
- Inserting Items into a List
- Removing Items from a List
- Removing Items Using Pop
- Removing Items Using Del
- Clearing List Items
- Copying a List
- Joining Lists
- Counting Items in a List
- Finding Index of an Item
- Reversing a List
- Sorting List Items
- π» Exercises: Day 5
Day 5
Lists
νμ΄μ¬μλ λ€ κ°μ§ 컬λ μ μλ£νμ΄ μμ΅λλ€.
- List: μ λ ¬λκ³ λ³κ²½ κ°λ₯(μμ κ°λ₯)ν 컬λ μ μ λλ€. μ€λ³΅ κ°μ νμ©ν©λλ€.
- Tuple: μ λ ¬λκ³ λ³κ²½ λΆκ°λ₯νκ±°λ μμ λΆκ°λ₯ν(λΆλ³) 컬λ μ μ λλ€. μ€λ³΅ κ°μ νμ©ν©λλ€.
- Set: μμκ° μ§μ λμ§ μκ³ μΈλ±μ€κ° μκ³ μμ ν μ μλ 컬λ μ μ΄μ§λ§ μ μμ΄ν μ μΆκ°ν μ μμ΅λλ€. μ€λ³΅ κ°μ νμ©λμ§ μμ΅λλ€.
- Dictionary: μ λ ¬λμ§ μκ³ λ³κ²½ κ°λ₯(μμ κ°λ₯)νλ©° μΈλ±μ€κ° μλ 컬λ μ μ λλ€. μ€λ³΅ κ°μ΄ μμ΅λλ€.
리μ€νΈλ μ λ ¬λκ³ μμ (λ³κ²½) κ°λ₯ν λ€μν μλ£νμ 컬λ μ μ λλ€. λͺ©λ‘μ λΉμ΄ μκ±°λ λ€λ₯Έ μλ£ν μμ΄ν μ κ°μ§ μ μμ΅λλ€.
How to Create a List
νμ΄μ¬μμ 리μ€νΈλ λκ°μ§ λ°©λ²μΌλ‘ μμ±ν μ μμ΅λλ€:
- list λ΄μ₯ ν¨μλ₯Ό μ¬μ©
empty_list = list() # μ΄κ±΄ λΉ λ¦¬μ€νΈ μ
λλ€, 리μ€νΈ μμ μ무 κ°λ μμ΅λλ€
print(len(empty_list)) # 0
- λκ΄νΈ μ¬μ©, []
empty_list = [] # μ΄κ±΄ λΉ λ¦¬μ€νΈ μ
λλ€, 리μ€νΈ μμ μ무 κ°λ μμ΅λλ€
print(len(empty_list)) # 0
μ΄κΈ° κ°μ΄ μλ 리μ€νΈμ λλ€. len() μ μ¬μ©νμ¬ λ¦¬μ€νΈμ κΈΈμ΄λ₯Ό μ°Ύμ΅λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon'] # list of fruits
vegetables = ['Tomato', 'Potato', 'Cabbage','Onion', 'Carrot'] # list of vegetables
animal_products = ['milk', 'meat', 'butter', 'yoghurt'] # list of animal products
web_techs = ['HTML', 'CSS', 'JS', 'React','Redux', 'Node', 'MongDB'] # list of web technologies
countries = ['Finland', 'Estonia', 'Denmark', 'Sweden', 'Norway']
# Print the lists and its length
print('Fruits:', fruits)
print('Number of fruits:', len(fruits))
print('Vegetables:', vegetables)
print('Number of vegetables:', len(vegetables))
print('Animal products:',animal_products)
print('Number of animal products:', len(animal_products))
print('Web technologies:', web_techs)
print('Number of web technologies:', len(web_techs))
print('Countries:', countries)
print('Number of countries:', len(countries))
output
Fruits: ['banana', 'orange', 'mango', 'lemon']
Number of fruits: 4
Vegetables: ['Tomato', 'Potato', 'Cabbage', 'Onion', 'Carrot']
Number of vegetables: 5
Animal products: ['milk', 'meat', 'butter', 'yoghurt']
Number of animal products: 4
Web technologies: ['HTML', 'CSS', 'JS', 'React', 'Redux', 'Node', 'MongDB']
Number of web technologies: 7
Countries: ['Finland', 'Estonia', 'Denmark', 'Sweden', 'Norway']
Number of countries: 5
- 리μ€νΈλ μλ‘ λ€λ₯Έ μλ£νμ μμ΄ν μ κ°μ§ μ μμ΅λλ€.
lst = ['Asabeneh', 250, True, {'country':'Finland', 'city':'Helsinki'}] # λ€λ₯Έ μλ£νμ κ°μ§ 리μ€νΈ
Accessing List Items Using Positive Indexing
μΈλ±μ€λ₯Ό μ¬μ©νμ¬ λ¦¬μ€νΈμ κ° μμ΄ν μ μ‘μΈμ€ν©λλ€. 리μ€νΈ μΈλ±μ€λ 0λΆν° μμν©λλ€. μλ κ·Έλ¦Όμ μΈλ±μ€κ° μμλλ μμΉλ₯Ό λͺ ννκ² λ³΄μ¬μ€λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
first_fruit = fruits[0] # μΈλ±μ€λ₯Ό μ¬μ©ν΄ 첫λ²μ§Έ μμ΄ν
μ μ κ·Όν©λλ€
print(first_fruit) # banana
second_fruit = fruits[1]
print(second_fruit) # orange
last_fruit = fruits[3]
print(last_fruit) # lemon
# Last index
last_index = len(fruits) - 1
last_fruit = fruits[last_index]
Accessing List Items Using Negative Indexing
μμ μΈλ±μ€λ λμμ μμνλ κ²μ μλ―Ένλ©° -1μ λ§μ§λ§ μμ΄ν μ, -2λ λ§μ§λ§μμ λλ²μ¨° μμ΄ν μ μλ―Έν©λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
first_fruit = fruits[-4]
last_fruit = fruits[-1]
second_last = fruits[-2]
print(first_fruit) # banana
print(last_fruit) # lemon
print(second_last) # mango
Unpacking List Items
lst = ['item','item2','item3', 'item4', 'item5']
first_item, second_item, third_item, *rest = lst
print(first_item) # item1
print(second_item) # item2
print(third_item) # item3
print(rest) # ['item4', 'item5']
# First Example
fruits = ['banana', 'orange', 'mango', 'lemon','lime','apple']
first_fruit, second_fruit, third_fruit, *rest = lst
print(first_fruit) # banana
print(second_fruit) # orange
print(third_fruit) # mango
print(rest) # ['lemon','lime','apple']
# Second Example about unpacking list
first, second, third,*rest, tenth = [1,2,3,4,5,6,7,8,9,10]
print(first) # 1
print(second) # 2
print(third) # 3
print(rest) # [4,5,6,7,8,9]
print(tenth) # 10
# Third Example about unpacking list
countries = ['Germany', 'France','Belgium','Sweden','Denmark','Finland','Norway','Iceland','Estonia']
gr, fr, bg, sw, *scandic, es = countries
print(gr)
print(fr)
print(bg)
print(sw)
print(scandic)
print(es)
Slicing Items from a List
- μμ μΈλ±μ±: start, end λ° stepμ μ§μ νμ¬ μμ μΈλ±μ€ λ²μλ₯Ό μ§μ ν μ μμ΅λλ€. λ°ν κ°μ μ 리μ€νΈκ° λ©λλ€. (startμ λν΄νΈκ° = 0, end = len(lst) - 1 (λ§μ§λ§ μμ΄ν ), step = 1)
fruits = ['banana', 'orange', 'mango', 'lemon']
all_fruits = fruits[0:4] # λͺ¨λ fruitsλ₯Ό λ°νν©λλ€
# μ΄κ²λν μμ κ°μ κ°μ λ°νν©λλ€
all_fruits = fruits[0:] # μ°λ¦¬κ° μ΄λμ λ©μΆ μ§ μ€μ νμ§ μμΌλ©΄, λͺ¨λ κ²μ ν¬ν¨ν©λλ€
orange_and_mango = fruits[1:3] # 첫λ²μ§Έ μΈλ±μ€λ₯Ό ν¬ν¨νμ§ μμ΅λλ€
orange_mango_lemon = fruits[1:]
orange_and_lemon = fruits[::2] # μ¬κΈ°μ μΈλ²μ§Έ μΈμμΈ stepμ μ¬μ©νμ΅λλ€. λͺ¨λ λλ²μ§Έ μμ΄ν
μ ν¬ν¨ν©λλ€ - ['banana', 'mango']
- μμ μΈλ±μ±: start, end λ° stepμ μ§μ νμ¬ μμ μΈλ±μ€μ λ²μλ₯Ό μ§μ ν μ μμ΅λλ€. λ°ν κ°μ μ 리μ€νΈκ° λ©λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
all_fruits = fruits[-4:] # λͺ¨λ fruitsλ₯Ό λ°νν©λλ€
orange_and_mango = fruits[-3:-1] # λ§μ§λ§ μΈλ±μ€λ₯Ό ν¬ν¨νμ§ μμ΅λλ€,['orange', 'mango']
orange_mango_lemon = fruits[-3:] # μ΄κ²μ -3 λΆν° μμνμ¬ λκΉμ§μ κ°μ μ€λλ€,['orange', 'mango', 'lemon']
reverse_fruits = fruits[::-1] # μμμ stepμ 리μ€νΈλ₯Ό μμμΌλ‘ κ°μ§λλ€,['lemon', 'mango', 'orange', 'banana']
Modifying Lists
리μ€νΈλ λ³κ²½ κ°λ₯νκ±°λ μμ κ°λ₯ν μμκ° μλ μμ΄ν λ€μ 컬λ μ μ λλ€. κ³ΌμΌ λ¦¬μ€νΈλ₯Ό μμ ν΄λ΄ μλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits[0] = 'avocado'
print(fruits) # ['avocado', 'orange', 'mango', 'lemon']
fruits[1] = 'apple'
print(fruits) # ['avocado', 'apple', 'mango', 'lemon']
last_index = len(fruits) - 1
fruits[last_index] = 'lime'
print(fruits) # ['avocado', 'apple', 'mango', 'lime']
Checking Items in a List
in μ°μ°μλ₯Ό μ¬μ©νμ¬ μμ΄ν μ΄ λ¦¬μ€νΈμ ꡬμ±μμΈμ§ νμΈν©λλ€. μλ μμλ₯Ό λ΄ μλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
does_exist = 'banana' in fruits
print(does_exist) # True
does_exist = 'lime' in fruits
print(does_exist) # False
Adding Items to a List
κΈ°μ‘΄ 리μ€νΈμ λμ μμ΄ν μ μΆκ°νλ €λ©΄ append() λ©μλλ₯Ό μ¬μ©ν©λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits.append('apple')
print(fruits) # ['banana', 'orange', 'mango', 'lemon', 'apple']
fruits.append('lime') # ['banana', 'orange', 'mango', 'lemon', 'apple', 'lime']
print(fruits)
Inserting Items into a List
insert() λ©μλλ₯Ό μ¬μ©νμ¬ λͺ©λ‘μ μ§μ λ μΈλ±μ€μ νλμ μμ΄ν μ μ½μ ν μ μμ΅λλ€. λ€λ₯Έ μμ΄ν λ€μ μ€λ₯Έμͺ½μΌλ‘ μ΄λνλ€λ κ²μ μ£Όμν©μλ€. insert() λ©μλλ μΈλ±μ€μ μ½μ ν μμ΄ν μ΄λΌλ λ κ°μ§ μΈμλ₯Ό κ°μ§λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits.insert(2, 'apple') # orangeμ mango μ¬μ΄μ appleμ μ½μ
print(fruits) # ['banana', 'orange', 'apple', 'mango', 'lemon']
fruits.insert(3, 'lime') # ['banana', 'orange', 'apple', 'lime', 'mango', 'lemon']
print(fruits)
Removing Items from a List
remove λ©μλλ 리μ€νΈμμ μ§μ λ μμ΄ν μ μμ ν©λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon', 'banana']
fruits.remove('banana')
print(fruits) # ['orange', 'mango', 'lemon', 'banana'] - μ΄ λ©μλλ 리μ€νΈμμ 첫λ²μ§Έλ‘ μ‘΄μ¬νλ μμ΄ν
μ μμ ν©λλ€
fruits.remove('lemon')
print(fruits) # ['orange', 'mango', 'banana']
Removing Items Using Pop
pop() λ©μλλ μ§μ λ μΈλ±μ€λ₯Ό μ κ±°ν©λλ€(λλ μΈλ±μ€κ° μ§μ λμ§ μμ κ²½μ° λ§μ§λ§ μμ΄ν ):
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits.pop()
print(fruits) # ['banana', 'orange', 'mango']
fruits.pop(0)
print(fruits) # ['orange', 'mango']
Removing Items Using Del
del ν€μλλ μ§μ λ μΈλ±μ€λ₯Ό μμ νλ©° μΈλ±μ€ λ²μ λ΄μ μμ΄ν μ μμ νλ λ°λ μ¬μ©ν μ μμ΅λλ€. λν 리μ€νΈλ₯Ό μμ ν μμ ν μλ μμ΅λλ€.
# syntax
lst = ['item1', 'item2']
del lst[index] # νλμ μμ΄ν
del lst # 리μ€νΈλ₯Ό μμ ν μμ
fruits = ['banana', 'orange', 'mango', 'lemon', 'kiwi', 'lime']
del fruits[0]
print(fruits) # ['orange', 'mango', 'lemon', 'kiwi', 'lime']
del fruits[1]
print(fruits) # ['orange', 'lemon', 'kiwi', 'lime']
del fruits[1:3] # μ΄κ²μ μ£Όμ΄μ§ μΈλ±μ€ μ¬μ΄μ μμ΄ν
μ μμ ν©λλ€, κ·Έλ¬λ―λ‘ μΈλ±μ€κ° 3μΈ μμ΄ν
μ μμ λμ§ μμ΅λλ€!
print(fruits) # ['orange', 'lime']
del fruits
print(fruits) # NameError: name 'fruits' is not defined κ° λ°μν΄μΌν©λλ€
Clearing List Items
clear() λ©μλλ₯Ό μ¬μ©ν΄ 리μ€νΈ λΉμ°κΈ°:
Copying a List
λ€μμ λ°©λ²μΌλ‘ μ λ³μμ μ¬ν λΉνμ¬ λ¦¬μ€νΈλ₯Ό 볡μ¬ν μ μμ΅λλ€:list2 = list1. μ΄μ list2λ list1μ μ°Έμ‘°μ΄λ©°, list2μμ λ³κ²½ν λ΄μ©μ μλ³Έ list1λ μμ ν©λλ€. νμ§λ§ μλ³Έμ μμ νκ³ μΆμ§ μκ³ λ€λ₯Έ μ¬λ³Έμ κ°κ³ μΆμ΄νλ κ²½μ°κ° λ§μ΅λλ€. μμ λ¬Έμ λ₯Ό νΌνλ ν κ°μ§ λ°©λ²μ copy() λ₯Ό μ¬μ©νλ κ²μ λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits_copy = fruits.copy()
print(fruits_copy) # ['banana', 'orange', 'mango', 'lemon']
Joining Lists
νμ΄μ¬μμ λ κ° μ΄μμ λͺ©λ‘μ κ²°ν©νκ±°λ μ°κ²°νλ λ°©λ²μ μ¬λ¬ κ°μ§κ° μμ΅λλ€.
- νλ¬μ€ μ°μ°μ (+)
positive_numbers = [1, 2, 3, 4, 5]
zero = [0]
negative_numbers = [-5,-4,-3,-2,-1]
integers = negative_numbers + zero + positive_numbers
print(integers) # [-5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5]
fruits = ['banana', 'orange', 'mango', 'lemon']
vegetables = ['Tomato', 'Potato', 'Cabbage', 'Onion', 'Carrot']
fruits_and_vegetables = fruits + vegetables
print(fruits_and_vegetables ) # ['banana', 'orange', 'mango', 'lemon', 'Tomato', 'Potato', 'Cabbage', 'Onion', 'Carrot']
- extend() λ©μλλ₯Ό μ¬μ©νμ¬ μ°κ²° extend() λ©μλλ₯Ό μ¬μ©νλ©΄ 리μ€νΈμ 리μ€νΈλ₯Ό μΆκ°ν μ μμ΅λλ€. μλ μλ₯Ό μ°Έμ‘°ν©μλ€.
num1 = [0, 1, 2, 3]
num2= [4, 5, 6]
num1.extend(num2)
print('Numbers:', num1) # Numbers: [0, 1, 2, 3, 4, 5, 6]
negative_numbers = [-5,-4,-3,-2,-1]
positive_numbers = [1, 2, 3,4,5]
zero = [0]
negative_numbers.extend(zero)
negative_numbers.extend(positive_numbers)
print('Integers:', negative_numbers) # Integers: [-5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5]
fruits = ['banana', 'orange', 'mango', 'lemon']
vegetables = ['Tomato', 'Potato', 'Cabbage', 'Onion', 'Carrot']
fruits.extend(vegetables)
print('Fruits and vegetables:', fruits ) # Fruits and vegetables: ['banana', 'orange', 'mango', 'lemon', 'Tomato', 'Potato', 'Cabbage', 'Onion', 'Carrot']
Counting Items in a List
count() λ©μλλ 리μ€νΈμ μμ΄ν μ΄ λνλλ νμλ₯Ό λ°νν©λλ€:
fruits = ['banana', 'orange', 'mango', 'lemon']
print(fruits.count('orange')) # 1
ages = [22, 19, 24, 25, 26, 24, 25, 24]
print(ages.count(24)) # 3
Finding Index of an Item
index() λ©μλλ 리μ€νΈμ μλ μμ΄ν μ μΈλ±μ€λ₯Ό λ°νν©λλ€:
fruits = ['banana', 'orange', 'mango', 'lemon']
print(fruits.index('orange')) # 1
ages = [22, 19, 24, 25, 26, 24, 25, 24]
print(ages.index(24)) # 2, μ²μ λ§λ κ²
Reversing a List
reverse() λ©μλλ 리μ€νΈμ μμλ₯Ό κ±°κΎΈλ‘ ν©λλ€.
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits.reverse()
print(fruits) # ['lemon', 'mango', 'orange', 'banana']
ages = [22, 19, 24, 25, 26, 24, 25, 24]
ages.reverse()
print(ages) # [24, 25, 24, 26, 25, 24, 19, 22]
Sorting List Items
리μ€νΈλ₯Ό μ λ ¬νλ €λ©΄ sort() λ©μλ λλ sorted() λ΄μ₯ ν¨μλ₯Ό μ¬μ©ν μ μμ΅λλ€. sort() λ©μλλ 리μ€νΈ μμ΄ν μ μ€λ¦μ°¨μμΌλ‘ μ λ ¬νκ³ μλ 리μ€νΈλ₯Ό μμ ν©λλ€. λ§μ½ sort() λ©μλμ reverseμ μΈμκ° trueλΌλ©΄, κ·Έκ²μ λͺ©λ‘μ λ΄λ¦Όμ°¨μμΌλ‘ λ°°μ΄ν κ²μ λλ€.
- sort(): μ΄ λ©μλλ μλ 리μ€νΈλ₯Ό μμ ν©λλ€
Example:
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits.sort()
print(fruits) # μνλ²³μμΌλ‘ μ λ ¬, ['banana', 'lemon', 'mango', 'orange']
fruits.sort(reverse=True)
print(fruits) # ['orange', 'mango', 'lemon', 'banana']
ages = [22, 19, 24, 25, 26, 24, 25, 24]
ages.sort()
print(ages) # [19, 22, 24, 24, 24, 25, 25, 26]
ages.sort(reverse=True)
print(ages) # [26, 25, 25, 24, 24, 24, 22, 19]
sorted(): μλ 리μ€νΈλ₯Ό μμ νμ§ μκ³ μ λ ¬λ 리μ€νΈλ₯Ό λ°νν©λλ€ Example:
fruits = ['banana', 'orange', 'mango', 'lemon']
print(sorted(fruits)) # ['banana', 'lemon', 'mango', 'orange']
# μμ
fruits = ['banana', 'orange', 'mango', 'lemon']
fruits = sorted(fruits,reverse=True)
print(fruits) # ['orange', 'mango', 'lemon', 'banana']
π λΉμ μ μ±μ€νκ³ μ΄λ―Έ λ§μ κ²μ μ±μ·¨νμ΅λλ€. μ¬λ¬λΆμ μ΄μ λ§ 5μΌμ°¨ λμ μ λ§μ³€κ³ μλν¨μ ν₯ν 5κ±Έμ μμ μμ΅λλ€. μ΄μ μ¬λ¬λΆμ λμ κ·Όμ‘μ μν μ΄λμ νμΈμ.
π» Exercises: Day 5
Exercises: Level 1
- λΉ λ¦¬μ€νΈλ₯Ό μ μΈν©λλ€
- 5κ° μ΄μμ μμ΄ν μ κ°λ 리μ€νΈλ₯Ό μ μΈν©λλ€
- λΉμ μ 리μ€νΈμ κΈΈμ΄λ₯Ό μμλ΄ λλ€
- 리μ€νΈμ 첫λ²μ§Έ, μ€κ°μ, λ§μ§λ§ μμ΄ν μ μ»μ΄λ΄ λλ€
- mixed_data_types λΌλ 리μ€νΈλ₯Ό μ μΈνκ³ , λΉμ μ μ΄λ¦, λμ΄, ν€, κ²°νΌ μ¬λΆ, μ£Όμλ₯Ό λ£μ΄λ΄ μλ€
- it_companies λΌλ μ΄λ¦μ λͺ©λ‘ λ³μλ₯Ό μ μΈνκ³ μ΄κΈ° κ°μ Facebook, Google, Microsoft, Apple, IBM, Oracle λ° Amazonμ ν λΉν©λλ€
- print() λ₯Ό μ¬μ©νμ¬ λ¦¬μ€νΈλ₯Ό νλ¦°νΈ ν©λλ€
- 리μ€νΈμ μλ κΈ°μ μλ₯Ό νλ¦°νΈ ν©λλ€
- 첫λ²μ§Έ, μ€κ°, λ§μ§λ§ κΈ°μ μ νλ¦°νΈ ν©λλ€
- κΈ°μ μ€ νλλ₯Ό μμ νκ³ λ¦¬μ€νΈλ₯Ό νλ¦°νΈ ν©λλ€
- it_companies μ νλμ IT κΈ°μ μ μΆκ°ν©λλ€
- νμ¬ λ¦¬μ€νΈ μ€κ°μ IT κΈ°μ μ μΆκ°ν©λλ€
- it_companies μ΄λ¦ μ€ νλλ₯Ό λλ¬Έμλ‘ λ³κ²½ν©λλ€ (IBM μ μΈ!)
- '#; ' λΌλ λ¬Έμμ΄λ‘ it_companies μ μ°κ²°ν©λλ€
- it_companies 리μ€νΈμ νΉμ κΈ°μ μ΄ μ‘΄μ¬νλ μ§ νμΈν©λλ€
- sort() λ©μλλ₯Ό μ¬μ©ν΄ 리μ€νΈλ₯Ό μ λ ¬ν©λλ€
- reverse() λ©μλλ₯Ό μ¬μ©νμ¬ λ¦¬μ€νΈλ₯Ό λ΄λ¦Όμ°¨μμΌλ‘ λ°μ ν©λλ€
- 리μ€νΈμμ μ²μ 3κ°μ κΈ°μ μ μλΌλ λλ€
- 리μ€νΈμμ λ§μ§λ§ 3κ°μ κΈ°μ μ μλΌλ λλ€
- 리μ€νΈμμ μ€κ°μ IT κΈ°μ λλ κΈ°μ λ€μ μλΌλ λλ€
- 리μ€νΈμμ 첫λ²μ§Έ IT κΈ°μ μ μμ ν©λλ€
- 리μ€νΈμμ μ€κ°μ IT κΈ°μ λλ κΈ°μ λ€μ μμ ν©λλ€
- 리μ€νΈμμ λ§μ§λ§ IT κΈ°μ μ μμ ν©λλ€
- 리μ€νΈμμ λͺ¨λ IT κΈ°μ μ μμ ν©λλ€
- IT κΈ°μ 리μ€νΈλ₯Ό μμ ν μ κ±°ν©λλ€
-
λ€μ 리μ€νΈλ₯Ό μ°κ²°ν©λλ€:
-
26λ² λ¬Έμ μ 리μ€νΈλ₯Ό μ°κ²°ν ν, μ°κ²°λ 리μ€νΈλ₯Ό 볡μ¬ν΄ full_stack λ³μμ ν λΉν©λλ€. κ·Έλ¦¬κ³ Python, SQL, Reduxλ₯Ό μ½μ ν©λλ€.
Exercises: Level 2
- λ€μμ 10λͺ μ νμμ λμ΄ λ¦¬μ€νΈμ λλ€:
- 리μ€νΈλ₯Ό μ λ ¬νκ³ μ΅μκ° λ° μ΅λκ° μ°Ύμ΅λλ€
- 리μ€νΈμ μ΅μκ° λ° μ΅λκ°μ λ€μ μΆκ°ν©λλ€
- λμ΄μ μ€μκ°μ μ°Ύμ΅λλ€(μ€κ° μμ΄ν νλ λλ μ€κ° μμ΄ν λ κ°λ₯Ό 2λ‘ λλ κ°)
- νκ· λμ΄λ₯Ό ꡬν©λλ€(λͺ¨λ μμ΄ν μ ν©μ κ°μλ‘ λλ κ°)
- λμ΄μ λ²μλ₯Ό ꡬν©λλ€(μ΅λκ° λΉΌκΈ° μ΅μκ°)
-
(μ΅μκ° - νκ· )κ³Ό (μ΅λκ° - νκ· )μ κ°μ λΉκ΅νκ³ abs() λ©μλλ₯Ό μ¬μ©ν©λλ€.
-
κ΅κ° λͺ©λ‘ μμ μ€κ° κ΅κ°λ₯Ό μ°Ύμ΅λλ€.
- κ΅κ° 리μ€νΈλ₯Ό λκ°μ 리μ€νΈλ‘ λλλλ€. μ§μλΌλ©΄ λκ°μ 리μ€νΈμ ν¬κΈ°κ° κ°κ², μλλΌλ©΄ μμ 리μ€νΈκ° νλμ κ΅κ°λ₯Ό λ κ°λλ‘ ν©λλ€.
- ['China', 'Russia', 'USA', 'Finland', 'Sweden', 'Norway', 'Denmark']. μμ μΈκ° κ΅κ°μ λλ¨Έμ§λ₯Ό scandic countriesλ‘ unpackν©λλ€.
π CONGRATULATIONS ! π