wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Программалау рубежка 1

Total questions: 78

Worksheet time: 1hrs 18mins

Name
Class
Date
1.

a=5; b=8; a==b

a)

false

b)

true

c)

a=b

d)

a==b

e)

not

2.

x=5; y=8; x!=y

a)

true

b)

false

c)

x=b

d)

x!=y

e)

not

3.

x1=15; x215; x1==x2

a)

true

b)

false

c)

x1=x2

d)

x1==x2

e)

not

4.

y1=15; y2=15; y1!=y2

a)

false

b)

true

c)

y1=y2

d)

y1!=y2b

e)

not

5.

z1=5; z2=8; z1==0

a)

false

b)

true

c)

z1!=0

d)

z1!=z2

e)

not

6.

a1=5; a2=8; a1>a2

a)

false

b)

true

c)

a1!=a2

d)

a1=a2

7.

b1=-5; b2=-8; b1>b2

a)

true

b)

false

c)

b1!=b2

d)

b1=b2

8.

c1=-5; c2=-8; c1>0

a)

false

b)

true

c)

c1!=0

d)

c1!=0

9.

for i in range(5):     print(i)

a)

0  1  2  3  4

b)

0  1  2  3  4  5

c)

1  2  3  4  5

d)

0  5

10.

for i in range(1,5):     print(i)

a)

1  2  3  4

b)

0  1  2  3  4

c)

1  2  3  4  5

d)

0  5

11.

for j in range(0,5,2):     print(j)

a)

0  2  4

b)

0  1  2  3  4

c)

1  3  5

d)

1  2  4

12.

for n in range(1,5,2):     print(n)

a)

1  3

b)

0  1  2  3  4

c)

1  3  5

d)

2  4

13.

for k in range(2,5):     print(k)

a)

2  3  4

b)

0  1  2  3  4

c)

2  3  4  5

d)

2  5

14.

for m in range(3,5):     print(m)

a)

3  4

b)

1  2  3  4

c)

2  3  4 

d)

2  5

15.

a=5; b=8;______ if a>0: print(a+1) _____else: print(b+2)

a)

6

b)

10

c)

a+1 

d)

b+2

16.

x=5; y=8;______ if x>0: print(‘x+1’) _____else: print(‘y+2’)

a)

x+1 

b)

6

c)

10

d)

y+2

17.

z1=5; z2=8;______ if z1<0: print(‘z1+1’) _____else: print(‘z2+2’)

a)

z2+2

b)

z1+1 

c)

6

d)

10

18.

a=5; b=8;______ if a<0: print(a+1) _____else: print(b+2)

a)

10

b)

b+2

c)

a+1 

d)

6

19.

y1=5; y2=8;______ if y2>0: print(y1+1) _____else: print(y2+2)

a)

6

b)

10

c)

y1+1 

d)

y2+2

20.

c1=5; c2=8;______ if c2>0: print(‘a+1’) _____else: print(‘b+2’)

a)

a+1 

b)

6

c)

10

d)

b+2

21.

m1=5; m2=8;______ if m2<0: print(‘m1+1’) _____else: print(‘m2+2’)

a)

m2+2

b)

m1+1 

c)

6

d)

10

22.

q=5; t=8;______ if t<0: print(q+1) _____else: print(t+2)

a)

10

b)

t+2

c)

q+1 

d)

6

23.

a1=5; a1+=6; print(a1)

a)

11

b)

5

c)

a1

d)

6

24.

a1=5; a1+=6; print(a1)

a)

-1

b)

5

c)

b1

d)

6

25.

a1=5; a1+=6; print(a1)

a)

-1

b)

5

c)

b1

d)

6

26.

s=5; s*=6; print(s)

a)

30

b)

5

c)

s

d)

6

27.

d=12; d/=6; print(d)

a)

2.0

b)

1/2

c)

d

d)

12

28.

n=2;  print(n**2)

a)

4

b)

2

c)

n**2 

d)

true

29.

r=2;  print(r**3)

a)

8

b)

2

c)

r**2 

d)

4

30.

h=1;  print(h**5)

a)

1

b)

2

c)

h**5 

d)

5

31.

p=1;  print(p**2)

a)

1

b)

2

c)

p**2

d)

5

32.

w=1;  print(w**4)

a)

1

b)

2

c)

w**4

d)

4

33.

x=6; x < 5 and  x < 10

a)

false

b)

true

c)

not 

d)

and

34.

z=6; z < 5 and  z < 10

a)

false

b)

true

c)

not

d)

and

35.

x = 30; ______if not x == 50: print('the value of x different from 50')

______else:  print('the value of x is equal to 50')

a)

the value of x different from 50

b)

'the value of x different from 50'

c)

'the value of x is equal to 50' 

d)

the value of x is equal to 50

36.

y = 40; ______if not y == 50: print('the value of x different from 50') ______else:  print('the value of x is equal to 50')

a)

the value of x different from 50

b)

'the value of x different from 50'

c)

'the value of x is equal to 50' 

d)

the value of x is equal to 50

37.

f = 50; ______if not f == 50: print('the value of x different from 50')

______else:  print('the value of x is equal to 50')

a)

the value of x is equal to 50

b)

'the value of x is equal to 50'

c)

'the value of x is equal to 40' 

d)

the value of x is equal to 40

38.

www = ["apple", "banana", "cherry"]

for u in www:  ______if u == "banana": continue   ______print(u)

a)

apple        cherry

b)

”apple”    “cherry”

c)

banana

d)

>”banana"

39.

fruits = ["apple", "banana", "cherry"]

for v in fruits:  ______if v == "apple": continue   ______print(v)

a)

banana        cherry

b)

apple          cherry

c)

banana        apple

d)

>”banana”

40.

e = ["apple", "banana", "cherry"]

for q5 in e:  ______if q5 == "cherry": continue   ______print(q5)

a)

apple        banana

b)

apple          cherry

c)

banana        cherry

d)

>”cherry”

41.

s = ["apple", "banana", "cherry"]

for x1 in s: ______________ print(x1)

______________ if x1 == "banana":break

a)

apple        banana

b)

apple          cherry

c)

banana        cherry

d)

>”cherry”

42.

fff = ["apple", "banana", "cherry"]

for r in fff: ______________ print(r)

______________ if r == "apple":break

a)

apple

b)

apple          cherry

c)

banana

d)

cherry

43.

bbb = ["apple", "banana", "cherry"]

for m in bbb: ______________ print(m)

______________ if m == "cherry":break

a)

apple          banana       cherry

b)

apple        banana

c)

apple          cherry

d)

banana        cherry

44.

print(type(452))

a)

class 'int'

b)

class 'float'

c)

class 'real' 

d)

class 'str’

45.

print(type(452.57))

a)

class 'float'

b)

class 'int'

c)

class 'real' 

d)

class 'str'

46.

print(type('YES'))

a)

class 'str'

b)

class 'float'

c)

class 'int'

d)

class 'real' 

47.

print(type(5+5j))

a)

class 'complex'

b)

class 'float'

c)

class 'int'

d)

class 'real' 

48.

x45 = 0; ________  while (x45 < 5):      print(x45);       x45 += 1

a)

0  1  2  3  4 

b)

0  1  2  3  4  5

c)

1  2  3  4 5

d)

0  1  2  3

49.

yy = 1; ________  while (yy < 5):      print(yy);       yy *= 2

a)

1  2  4 

b)

0  1  2  3  4  5

c)

1  2  3  4   

d)

0  1  2  3

50.

xx = 1; ________  while (xx < 5):      print(xx);       xx *= 3

a)

1  3 

b)

1  2 

c)

1  2  3  4   

d)

1  2  3

51.

aaa=5; bbb=8;______ if aaa<0: print(‘aaa+1’) _____else: print(‘bbb+2’)

a)

bbb+2

b)

aaa+1 

c)

10

d)

true

52.

ba=5;b bb=8;______ if ba<0: print(ba+1) _____else: print(bb+2)

a)

10

b)

bb+2

c)

ba+1 

d)

6

53.

Жұп санды тексеретін шарт

a)

if a%2==0

b)

if a%2!=0

c)

if a%3==0

d)

if a%3!=0

54.

Тақ санды тексеретін шарт

a)

if a%2!=0

b)

if a%2==0

c)

if a%3==0

d)

if a%3!=0

55.

3-ке бөлінетін сандарды тексеретін шарт

a)

if a%3==0

b)

if a%2!=0

c)

if a%2==0

d)

if a%3!=0

56.

5-ке бөлінбейтін сандарды тексеретін шарт

a)

if a%5!=0

b)

if a%3!=0

c)

if a%2!=0

d)

if a%2==0

57.

math.pow(5,3) ұқсас орындалатын оператор

a)

5**3

b)

3**5

c)

5*3

d)

3*5

58.

8**9  әрекетіне ұқсас  орындалатын оператор

a)

math.pow(8,9)

b)

math.pow(9,8)

c)

math.pow(9,9)

d)

math.pow(8**9)

59.

print(math.pow(4,3))  ке ұқсас амал орындалатын оператор

a)

print(4**3)

b)

print(3**4)

c)

print(4*3)

d)

print(math(4,3))

60.

print(5**6) -ке  ұқсас орындалатын оператор

a)

print(math.pow(5,6))

b)

print(math.pow(6,5))

c)

print(math.pow(5,5))

d)

print(math.pow(5**6))

61.

print(5%2)

a)

1

b)

0

c)

2

d)

3

62.

print(8%2)

a)

0

b)

1

c)

2

d)

3

63.

print(6%8)

a)

6

b)

1

c)

2

d)

0

64.

print(6//4)

a)

1

b)

3

c)

2

d)

0

65.

print(8//4)

a)

1

b)

3

c)

2

d)

0

66.

8%2  әрекетіне ұқсас  орындалатын оператор

a)

math.fmod(8,2)

b)

math.pow(8,2)

c)

math.mod(8,2)

d)

math.fmod(8,3)

67.

print(math.fmod(9,2))

a)

1.0

b)

3.0

c)

2.0

d)

0

68.

Қалдық есептейтін математикалық функция

a)

math.fmod(x,y)

b)

math.pow(x,y)

c)

math.ceil(x)

d)

math.mod(x,y)

69.

print(math.factorial(4))

a)

24

b)

120

c)

6

d)

30

70.

i=0; while i<=10: ____    i=i+1    ____   if i==7:          break   ____    print(i)     

a)

1  2  3  4  5  6

b)

1 2 3 4 5 6 7 8 9 10

c)

1 2 3 4 5 6 7

d)

0 1 2 3 4 5 6 7 8 9

71.

a=(3,-5,1,2, 4, 1); s=0   ____for i in a:      if i%2==0:    s=s+1   ____print(s)

a)

2

b)

1

c)

3

d)

4

72.

b=(3,-5,1,2, 4, 1); s=0 _____ for i in b:      if i%2!=0:      s=s+1 _____print(s)

a)

4

b)

2

c)

3

d)

1

73.

z=(0,3,-5,1,2, 0, 1); s=0  _____for j in z:      if j==0:          s=s+1 ____print(s)

a)

2

b)

4

c)

3

d)

1

74.

y=(7,-3,0,1,2, 0, 1); n=0  _____for j in y:      if j!=0:        n=n+1 _____print(s)

a)

5

b)

4

c)

3

d)

1

75.

x=(1,-3,0,1,2,0,1); s=0  ____for j in x:       s=s+j   _____print(s)

a)

2

b)

5

c)

4

d)

3

76.

d=(2,-3,0,-1,2,0,1); s=0 _____for j in x:       if j<0:         s=s+j    ____print(s)

a)

-4

b)

-3

c)

4

d)

3

77.

xy=(-2,-3,0,-1,2,0,1); s=0 _____for j in xy:      if j>0:        s=s+j   ______print(s)

a)

3

b)

2

c)

5

d)

4

78.

Автор

a)

красавчик

b)

молодец