
Строки в Python. Первое знакомство

Quiz
•
Computers
•
10th Grade
•
Hard
Ольга Перескокова
Used 19+ times
FREE Resource
10 questions
Show all answers
1.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Дана строка
s = "автомобиль"
С помощью среза получите новую строку q, в которой будет слово "авто".
Пробелы в ответе не ставьте
2.
MULTIPLE SELECT QUESTION
2 mins • 1 pt
Дана строка s = "гипербола".
Какие команды нужно написать, чтобы получить слово "перо"
print(s[2:5] + s[6])
t = s[2:-2]
print(t[:3] + t[4])
t = s[2:-2]
print(t[:3] + t[6])
print(s[2:5] + s[7])
3.
FILL IN THE BLANK QUESTION
30 sec • 1 pt
Дана строка s = "еле-еле едет".
Что будет выведено командой
print(s.count('e'))
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Какой метод позволяет найти самое левое вхождение подстроки substr в строке str?
str.find(substr)
substr.find(str)
str.rfind(substr)
substr.rfind(str)
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Какой метод позволяет найти самое правое вхождение подстроки substr в строке str?
str.find(substr)
substr.find(str)
str.rfind(substr)
substr.rfind(str)
6.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Дана строка s. Как с помощью среза получить последние два символа этой строки? В ответе пробелы не ставьте.
7.
MULTIPLE SELECT QUESTION
1 min • 1 pt
Дана строка s = "перо".
Как можно сформировать новую строку q, в которой будет слово "опер"?
q = s[4]+s[1]+s[2]+s[3]
q = s[3]+s[:3]
q = s[-1]+s[-2::-1][::-1]
q = s[len(s)] + s[:-1:-1]
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
Python Basics: Operators and Variables

Quiz
•
10th Grade
12 questions
Python Unit 2 Quiz 2

Quiz
•
9th - 12th Grade
10 questions
String Methods

Quiz
•
9th - 12th Grade
15 questions
Python 10 Bài 4

Quiz
•
10th Grade
15 questions
Python Veri Tipleri

Quiz
•
10th Grade
15 questions
ASK F2 -KOD ARAHAN (PYTHON)

Quiz
•
1st Grade - University
10 questions
Cấu trúc lặp - Python

Quiz
•
9th - 12th Grade
15 questions
Intermediate Python

Quiz
•
9th - 11th 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