wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Python-3.2. Функциялар тест

Total questions: 20

Worksheet time: 10mins

Name
Class
Date
1.

F-string қалай жазылады?

a)

print(“Сан:”+5)

b)

print(“Сан:{ }”)

c)

print(“Сан:”,5)

d)

print(f-str(5))

2.

input() функциясы не қайтарады?

a)

int

b)

float

c)

str

d)

bool

3.

list(range(1,5)) нені қайтарады?

a)

[0,1,2,3,4]

b)

[1,2,3,4,5]

c)

[1,2,3,4]

d)

[0,1,2,3,4,5]

4.

Сан енгізу үшін не істейміз?

a)

input(“Сан:”)

b)

int(input(“Сан:”))

c)

str(input(“Сан:”))

d)

print(input(“Сан:”))

5.

“python”.find(“t”) нені қайтарады?

a)

0

b)

1

c)

2

d)

3

6.

“hello world”.split(“o”) нені қайтарады?

a)

[“hell”,””,”w”,””,”rld”]

b)

[“hello”,”world”]

c)

[“h”,””,”ell”,””,”w”,””,”rld”]

d)

[“hell”,”world”]

7.

abs(-5) нені қайтарады?

a)

-5

b)

5

c)

0

d)

Error

8.

print(1,2,3, sep=“|”) нені шығарады?

a)

1 2 3

b)

1|2|3

c)

123|||

d)

1,2,3

9.

Төмендегі кодтың нәтижесі қандай? If 5>3: Print(“Иә”)

a)

Error

b)

Иә

c)

Жоқ

d)

Ештеңе шығармайды

10.

round(3.7) не қайтарады?

a)

3

b)

4

c)

3,7

d)

5

11.

end параметрі не үшін қажет?

a)

Мәндер арасындағы бөлгішті анықтайды

b)

Жол соңын анықтайды

c)

Мәтінді үлкен әріпке айналдырады

d)

Сандарды қосады

12.

print(“Сәлем”) не шығарады?

a)

Сәлем

b)

“Сәлем”

c)

Error

d)

Ештеңе шығармайды

13.

sorted([3,1,4,2]) нені қайтарады?

a)

[3,1,4,2]

b)

[1,2,3,4]

c)

[4,3,2,1]

d)

[1,3,2,4]

14.

print(1,2, sep+“-”) нені шығарады?

a)

1 2

b)

1-2

c)

12

d)

1,2

15.

\n символы не істейді?

a)

Табуляция қосады

b)

Жолды келесі қатарға көшіреді

c)

Бос орын қосады

d)

Жолды жояды

16.

pow(2,3) функциясы нені қайтарады?

a)

6

b)

8

c)

9

d)

5

17.

max(3,7,2,9) функциясы нені қайтарады?

a)

3

b)

7

c)

2

d)

9

18.

print(“Сәлем”, end=“!”) нені шығарады?

a)

Сәлем!

b)

Сәлем!!

c)

С!ә!л!е!м!

d)

Error

19.

“hello”.replace(“l”,“L”) нені қайтарады?

a)

“hello”

b)

“heLLo”

c)

“heLLo”

d)

“hELLo”

20.

Len(“python”) функциясы нені қайтарады?

a)

5

b)

6

c)

8

d)

7