Python списки

Quiz
•
Computers
•
10th Grade
•
Hard
Used 49+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Что выполняет данный фрагмент кода?
numList = list(map(int, input().split()))
numList = numList[::2]
print(' '.join(map(str, numList)))
Вычисляет сумму всех четных элементов списка введенных с клавиатуры
Выводит список всех четных элементов списка введенных с клавиатуры
Выводит в строку все элементы списка введённого с клавиатуры, стоящие на четных местах
Вычисляет длину списка
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Что будет напечатано после выполнения данного фрагмента кода?
a = [1, 2, 3]
a[1] = 3
print(a)
[1, 2, 3]
[1, 3, 3]
3
[3, 2, 3]
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
В результате выполнения кода
a = [0, 1]
b = a
a = [2, 3]
print(b)
Будет напечатано
[2, 3]
[0, 1]
2 3
0 1
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Что будет напечатано после выполнения данного кода:
numList = [1, 2, 3, 4, 5, 6]
numList = [i for i in numList if i % 2 == 0]
print(' '.join(map(str, numList)))
[1, 3, 5]
[2, 4, 6]
1 3 5
2 4 6
5.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Что будет выведено в результате выполнения данного кода?
numList = [0, 1, 2, 3, -1, -2, -3]
numList = [i for i in numList if i > 0]
print(len(numList))
3
0 1 2 3
[0, 1, 2, 3]
4
6.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Запустив программу
alist = list(map(int, input().split()))
maxa = max(alist)
print(alist, maxa)
пользователь ввел:
1 2 3 4 5
Что выведет программа?
[1, 2, 3, 4, 5] 5
1 2 3 4 5 5
5
5 [1, 2,3,4,5]
7.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Дан следующий код:
nlist = [1, 2, 3]
mlist = list(map(lambda i: i**3, nlist))
print(*mlist)
в результате его запуска будет выведено...
1 4 9
3 6 9
1 8 27
[1 4 9]
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
Python: обработка строк

Quiz
•
8th - 10th Grade
15 questions
JavaScript Quiz

Quiz
•
9th - 10th Grade
12 questions
CSPUnit6AssessmentReview

Quiz
•
9th - 12th Grade
15 questions
Hyperlink Tags (HTML)

Quiz
•
6th - 12th Grade
15 questions
APCSP Semester 1 Review

Quiz
•
10th Grade
12 questions
Python list starter

Quiz
•
10th Grade - University
14 questions
Интерфейс Scratch 3.0

Quiz
•
1st - 11th Grade
10 questions
Алфавит и словарь языка Python

Quiz
•
9th - 12th Grade
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
15 questions
Core 4 of Customer Service - Student Edition

Quiz
•
6th - 8th Grade
15 questions
What is Bullying?- Bullying Lesson Series 6-12

Lesson
•
11th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
10 questions
Proper Keyboarding Techniques

Interactive video
•
6th - 10th Grade
10 questions
Understanding Computers: Hardware, Software, and Operating Systems

Interactive video
•
7th - 12th Grade
29 questions
AP CSP Unit 2 Review (Code.org)

Quiz
•
10th - 12th Grade