
Python - palindrom, tekst, do zadań losowych
Quiz
•
Computers
•
9th Grade
•
Practice Problem
•
Medium
KP KP
Used 4+ times
FREE Resource
Enhance your content in a minute
13 questions
Show all answers
1.
FILL IN THE BLANK QUESTION
45 sec • 1 pt
Aby zamienić liczbę dziesiętną na binarną użyjesz funkcji:
2.
FILL IN THE BLANK QUESTION
45 sec • 1 pt
Aby zamienić liczbę dziesiętną na szesnastkową użyjesz funkcji:
3.
FILL IN THE BLANK QUESTION
45 sec • 1 pt
Aby zamienić liczbę dziesiętną na ósemkową użyjesz funkcji:
4.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Aby wypisać pierwszą literę zmiennej nazwisko:
nazwisko = "Rossum"
print(nazwisko[-1])
print(nazwisko[0])
print(nazwisko[:1])
print(nazwisko[1:])
Answer explanation
To print the first letter of the variable 'nazwisko', use print(nazwisko[0]). This will access the first character 'R' in the string 'Rossum'.
5.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Aby wypisać ostatnią literę zmiennej nazwisko:
nazwisko = "Rossum"
print(nazwisko[-1])
print(nazwisko[0])
print(nazwisko[:1])
print(nazwisko[1:])
Answer explanation
To print the last letter of the variable 'nazwisko', use 'print(nazwisko[-1])'. This will access the last character in the string 'Rossum'.
6.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Aby wypisać pierwszych 5 znaków zmiennej nazwisko:
nazwisko = "Guido van Rossum"
wybierz wszystkie poprawne
print(nazwisko[:-1])
print(nazwisko[5:])
print(nazwisko[0:5])
print(nazwisko[:5])
Answer explanation
To print the first 5 characters of the variable 'nazwisko', you can use print(nazwisko[0:5]) or print(nazwisko[:5]). These slices will output 'Guido'.
7.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Aby wypisać nazwisko od końca:
nazwisko = "Guido van Rossum"
print(nazwisko[::-1])
print(nazwisko[:-1])
print(nazwisko[-1:])
print(nazwisko[:-1])
Answer explanation
The correct choice is print(nazwisko[::-1]) because using the slicing syntax [::-1] allows us to reverse the string 'Guido van Rossum'.
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
14 questions
year 8 lesson 2 quiz - python
Quiz
•
8th - 10th Grade
17 questions
"switch" Java Statement - 1
Quiz
•
9th - 10th Grade
14 questions
Kiểu dữ liệu xâu kí tự - xử lí xâu kí tự
Quiz
•
9th - 12th Grade
15 questions
Arduino
Quiz
•
7th - 9th Grade
15 questions
History of Computers
Quiz
•
6th - 12th Grade
16 questions
Python Basics
Quiz
•
KG - University
10 questions
Perangkat Komputer
Quiz
•
1st - 12th Grade
12 questions
Python Programming - Iteration
Quiz
•
9th Grade
Popular Resources on Wayground
25 questions
Multiplication Facts
Quiz
•
5th Grade
15 questions
4:3 Model Multiplication of Decimals by Whole Numbers
Quiz
•
5th Grade
10 questions
The Best Christmas Pageant Ever Chapters 1 & 2
Quiz
•
4th Grade
12 questions
Unit 4 Review Day
Quiz
•
3rd Grade
20 questions
Christmas Trivia
Quiz
•
6th - 8th Grade
18 questions
Kids Christmas Trivia
Quiz
•
KG - 5th Grade
14 questions
Christmas Trivia
Quiz
•
5th Grade
15 questions
Solving Equations with Variables on Both Sides Review
Quiz
•
8th Grade
