Что делает следующий код?
with open("data.txt", "w") as file:
file.write("Hello, world!")
СОР (пересдача) 10 класс
Quiz
•
Computers
•
10th Grade
•
Medium
Yulian Serpokryl
Used 3+ times
FREE Resource
8 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 3 pts
Что делает следующий код?
with open("data.txt", "w") as file:
file.write("Hello, world!")
Ничего не делает.
Создаёт файл data.txt и записывает в него текст.
Считывает текст из файла data.txt
Удаляет файл data.txt.
2.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Для чего нужен метод sort() в Python?
Для копирования списка.
Для изменения строки.
Для сортировки списка.
Для сложения чисел.
3.
MULTIPLE CHOICE QUESTION
30 sec • 3 pts
Что вернёт функция?
def add(a, b):
return a + b
print(add(2, 3))
4.
DRAG AND DROP QUESTION
1 min • 4 pts
Переменная служит для (a) данных.
Цикл это (b) действий.
Функция служит для выполнения (c) .
5.
DROPDOWN QUESTION
1 min • 2 pts
Какой режим работы файла используется для добавления данных в конец файла? (a)
6.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Что выведет следующий код?
def square(x):
return x * x
print(square(4))
7.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Какой результат выполнения этого кода?
s = "Программирование"
print(s[:6])
Програ
Программ
Програм
Программирование
8.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Как создается функция в Python?
12 questions
Python Сестрорецк №10 Тест по функциям
Quiz
•
9th - 12th Grade
8 questions
10 класс СОР-3 (2 четверть)
Quiz
•
10th Grade
10 questions
Функции def
Quiz
•
9th - 12th Grade
10 questions
Информатика by timoxa.666
Quiz
•
9th - 12th Grade
13 questions
python для новичков
Quiz
•
4th - 11th Grade
13 questions
Python: процедуры и функции
Quiz
•
8th - 11th Grade
10 questions
files + pyQt notes
Quiz
•
9th - 12th Grade
10 questions
Протоколы сети Интернет
Quiz
•
10th - 11th Grade
15 questions
Multiplication Facts
Quiz
•
4th Grade
20 questions
Math Review - Grade 6
Quiz
•
6th Grade
20 questions
math review
Quiz
•
4th Grade
5 questions
capitalization in sentences
Quiz
•
5th - 8th Grade
10 questions
Juneteenth History and Significance
Interactive video
•
5th - 8th Grade
15 questions
Adding and Subtracting Fractions
Quiz
•
5th Grade
10 questions
R2H Day One Internship Expectation Review Guidelines
Quiz
•
Professional Development
12 questions
Dividing Fractions
Quiz
•
6th Grade
25 questions
Spanish preterite verbs (irregular/changed)
Quiz
•
9th - 10th Grade
10 questions
Juneteenth: History and Significance
Interactive video
•
7th - 12th Grade
8 questions
"Keeping the City of Venice Afloat" - STAAR Bootcamp, Day 1
Quiz
•
9th - 12th Grade
20 questions
Distance, Midpoint, and Slope
Quiz
•
10th Grade
20 questions
Figurative Language Review
Quiz
•
10th Grade
20 questions
Understanding Linear Equations and Slopes
Quiz
•
9th - 12th Grade