Предмет:
ИнформатикаАвтор:
stuart701. list1 = ['q', 'w']
2. list1.extend(['a', 'b', 'c', 'd', 'e'])
3. list2 = ['x', 'y', 'z']
4. list1.extend(list2)
5. list1.insert(4, 'Python')
6. list1.insert(5, 'Java')
7. list1.insert(4, 'Sharp')
8. list1.remove('Sharp')
9. list1.remove('q')
10. list1.remove('w')
Автор:
harleynyj4# 1. Create a list with elements 'q' and 'w'
list1 = ['q', 'w']
# 2. Add 5 more elements to the list
list1 += ['a', 'b', 'c', 'd', 'e']
# 3. Create a second list and add 3 elements to it
list2 = ['x', 'y', 'z']
# 4. Concatenate the two lists
list3 = list1 + list2
# 5. Insert the word 'Python' at index 4
list3.insert(4, 'Python')
# 6. Insert the word 'Java' at index 5
list3.insert(5, 'Java')
# 7. Insert the word 'Sharp' at index 4
list3.insert(4, 'Sharp')
# 8. Remove the word 'Sharp'
list3.remove('Sharp')
# 9. Remove the word 'q'
list3.remove('q')
# 10. Remove the word 'w'
list3.remove('w')
Автор:
ravenukovДобавить свой ответ
Предмет:
Английский языкАвтор:
marissaОтветов:
Смотреть
Предмет:
Русский языкАвтор:
chandler50Ответов:
Смотреть