Quiz
ITE3711 New
This quiz has question types that open in the usual player.
Questions in this quiz (63)
1What is the result of 2 + 3 * 4 in Python?
- A12
- B14
- C20
- D18
2Which of the following is a valid variable name in Python?
- A1variable
- Bmy_variable
- Cvariable-1
- Dvar&ble
3What will be the output of print("Hello" * 3) in Python?
- AHelloHelloHello
- B9
- CHello 3 times
- DRasengan
4In Python, which statement is used to make a decision based on a condition?
- Afor
- Bswitch
- Cif
- Dmizu no ko kyuu ichi no kata mina mo giri
5How do you define a function in Python?
- Afunction myFunction():
- Bdefine myFunction():
- Cdef myFunction():
- Dfunc myFunction():
6 What is the correct way to call a function named my_function with two arguments in Python?
- Acall my_function()
- Bfunction my_function()
- Cmy_function(arguments)
- Dmy_function(arg1, arg2)
7What will the following code snippet output: 5 > 3 and 10 < 20?
- ATrue
- BFalse
- CError
- Dsan no kata ryuu ryuu mai
8Which data type can not execute a calculation in Python?
- Astring
- Binteger
- Cfloat
- Dall of above
9What does the "return" statement do in a function?
- ATerminates the function
- BReturns a value from the function
- CPrints a message
- DSkips the function
10What is the result of range(7) in Python?
- A1,2,3,4,5,6
- B0,1,2,3,4,5,6
- C0,1,2,3,4,5,6,7
- D1,2,3,4,5,6,7
11Which of the following program segment (s) is an example of a compound(複合的) conditional statement in Python?
- Aif x > 5 or y < 10:
- Bif x > 5 and y < 10:
- Cif x > 5 then y < 10:
- Dif x > 5
12What is the output of print(3 == 3) in Python?
- ATrue
- BFalse
- C3
- D( 0 ﹏ 0 )
13What is the purpose of the not keyword in Python?
- ANegates a boolean value
- BPerforms bitwise NOT operation
- CIndicates a negative number
- Dkakebunshin no jutsu
14What will be the output of the following code snippet?

- A3
- B3.5
- C4
- DError
15What does the != operator signify in Python?
- ALess than or equal to
- BNot equal to
- CGreater than or equal to
- DAssignment
16 What will be the output of the following code snippet?

- AOut of range
- BIn range
- Cout of range
- DZaphkiel Bet
17What is the value of z after the execution of the following code snippet?
def my_function(x, y):
return x + y
z = my_function(3, 4) * 2
- A14
- B24
- C7
- D68
18What is the value of z after the execution of the following code snippet?

- A86
- B68
- C14
- Derror
19What will be the output of the following code snippet?

- A55
- B"55"
- C"52"
- D10
20What will be the output of the following code snippet?

- A3.33333
3 - B3
3.33333 - Cerror
- D3 / 3
3 // 3
- A3.33333
21 What is the result of True + True in Python?
- ATrue
- B2
- CFalse
- DLook at Move!! Faker!! What was that !!!
22Are you ready for the test?
- AAbsolute Cinema

- BYes

- CNo

- DWill Win

- AAbsolute Cinema
23What will be the output of the following code snippet?

- A2
3 - B2
2.66666 - C8
3 - D2.66666
2
- A2
24What will be the output of the following code snippet?

- A2.5
- B0.4
- C2
- D6
25What is the value of the result variable in the following code snippet?

- A5
- B10
- C7
- D52
26What does the += operator do in Python?
- ASubtracts the right operand from the left operand
- BMultiplies the left operand by the right operand
- CAdds the right operand to the left operand
- DNone of the above
27What will be the output of the following code snippet?

- A"52"
- B7
- C52
- D10
28What is the result of (True or False and True) in Python?
- ATrue
- BFalse
- CError
- DNone of the above
29What does the // operator do in Python?
- ACalculates the remainder
- BPerforms floor division
- CRaises to the power
- DRyōiki tenkai "Muryō kuusho"
30the display output of
print (f" Answer = { name } ")
is equivalent to
print ("Answer = name")- ATrue
- BFalse
31Write a Python program segment to ask "the user to input their test mark" and store it in the test variable as a float type. The programme should ask the user a question "What is your test result? >"
[blank_start]test[blank_end] = [blank_start]float([blank_end][blank_start]input([blank_end][blank_start]"What is your test result? >"[blank_end][blank_start]))[blank_end]- Atest
- Btext
- Cfloat(
- Dint(
- Estr(
- Finput(
- Goutput(
- H"What is your test result? >"
- I"What is your test result?"
- J"What is your text result? >"
- K"what is your text result? >"
- L"What is your text result?>"
- M))
32The Data type of variable "Future" is String
SYNY = 1
Future = SYNY == "True"- ATrue
- BFalse
33Which of the following variable names uses the snake case approach?
- A3711ModuleCode
- BSeeYouNextYear
- CHKIIT_Modules
- Dif
34Which of the following variable names uses the camel case approach?
- AseeYouNextYear
- BHKIIT_Modules
- C3711moduleCode
- D____main____
35Which of the following variable names uses the Pascal Case approach?
- ASee You Next Year
- BSee_You_Next_Year
- CSeeYouNextYear
- Difelse
36What is the correct way to declare a variable in Python?
- Acreate variable mark is 100;
- Bx <- 100
- Cdim Sum As Integer = "HarGow";
- DSeeYouNextYear = "Higher Diploma"
37What is the value of the variable Result stored when the following Python segment is executed?

- AI choose You Pikachu
- Bonly children need to choose
- CI choose You
- Donly children need to choose Pikachu
38Which of the following Python segments is/are able to execute the below function CallMe()?

- ACallMe(21850000)
- BCallMe("Me","21800000")
- CcallMe("Me","21800000")
- DCallMe("pizza",str(21800000))
39Which of the following Python segments able to execute the provided function CallMe() and display the result
21850000 Call Me
- ACallMe("21800000","Me")
- BCallMe(21850000,"Me")
- Cprint(CallMe("21800000","Me"))
- Dprint("21800000","Me")
40Which operator is used to calculate reminders in Python?
- A%>%
- B//
- C%
- D_(¦3」∠)_
41Which of the following Python code is a correct answer to the following expression?
Expression: 73% of 467- A467 * 0.73
- B467 // 0.73
- C467 * 73%
- D467 // 73/100
42Which of the following is/are a software development stage?
- APlanning
- BAnalysis
- CDesign
- DImplementation
- EKaton Goukakyuu no jutsu
43What is the output of the following program segment?
print(10*(3.7 + 2.3))- A60
- B60.0
- C"60.0"
- Dえどてんせい
44What is the displayed result of the Python program segment?

- AGoodGood Bye
- B=========
=========
GoodGood Bye - C=========
GoodGood Bye
========= - D=========
Jutsushiki jyunten "Ao", Jutsushiki hanten "Aka"
=========
45What is the python expression that can represent the following mathematics equation?

- A(a + b) ** (5/2)
- B(a + b) ** (2/5)
- C(a + b) ^ (2/5)
- D(a + b) ^ (5/2)
46Choose all of the following Python expression(s) that are possible to represent the displayed mathematics equation.

- A(a + b) ** (2/5)
- B(a**2 + 2*a*b + b**2) ** (1/5)
- C((a+b)(a+b)) ** (1/5)
- D(a + b) ** (5/2)
- Ea ゚∀ ゚) ゚∀゚)b
47What is the displayed result when the following Python code executed?

- AGGWP
WPGG - BWPGG
GGWP - CError
- DGGWP
- EWPGG
- AGGWP
48What will be the output of the following code segnment?

- A7
- B3
- CError
- D

49What will be the output of the following code segment?

- A7
- BError
- CNone
- D

50What happens if a function in Python does not have a return statement?
- AIt returns None
- BIt raises an error
- CThe function does not execute
- DIt returns the last expression evaluated
51Identify the data type of the following variables.

- Astring
- Bfloat
- Cinteger
- Dfloat
- Eboolean
52Ans = 0
[blank_start]for[blank_end] [blank_start]count[blank_end] [blank_start]in[blank_end] [blank_start]range(1,6)[blank_end]:
[blank_start]Ans[blank_end] [blank_start]+=[blank_end] [blank_start](2 * count) ** count[blank_end]
- Afor
- Bwhile
- CI don't know fuck!
- Dcount
- EAns
- Fin
- Gon
- Hat
- Iunder
- Jrange(1,6)
- Krange(0,5)
- Lrange(6)
- Mrange(5)
- Nrange(6,1)
- OAns
- Pcount
- Q+=
- R-=
- S*=
- T(2 * count) ** count
- U(2 ** count) * count
- V(count ** count) * 2
- W(count * count) ** 2
53sum = 0
count = 1
while [blank_start]count <= 5[blank_end]:
[blank_start]sum[blank_end] [blank_start]+=[blank_end] [blank_start](count * 2) ** (2 * count -1)[blank_end]
[blank_start]count += 1[blank_end]
- Acount <= 5
- Bcount < 5
- Csum
- D+=
- E(count * 2) ** (2 * count -1)
- F(count * 2) ** (2 * count +1)
- Gcount += 1
- Hcount + 1
- I1 / ((count * 2) ** (2 * count -1))
- J1 / (count * 2) ** (2 * count -1)
- K1 / ((count * 2) ** (2 * count +1))
- L1 / (count * 2) ** (2 * count +1)
- M1 / ((count ** 2) * (2 ** count -1))
54count = 1
sum = 0
[blank_start]while[blank_end] [blank_start]count <= 5:[blank_end]
sum += [blank_start](2 * count) ** count[blank_end]
[blank_start]count += 1[blank_end]
- Awhile
- Bfor
- Cwhen
- Dcount <= 5:
- Ecount < 5:
- Fcount <= 5
- Gcount < 5
- H(2 * count) ** count
- I(2 ** count) * 2
- J(2 ** count) * count
- Kcount += 1
- Lcount += 2
- Mcount += 5
- Ncount + 1
55sum = 0
#below is the for loop
For [blank_start]count[blank_end] [blank_start]in[blank_end] [blank_start]range(1,6):[blank_end]
sum [blank_start]+=[blank_end] [blank_start]1/((count * 2) ** ( 2 * count -1))[blank_end]
- Acount
- Bsum
- Ccount += 1
- Din
- Eon
- Fat
- Grange(1,6):
- Hrange(1,5):
- Irange(1,6)
- Jrange(6):
- Krange(1,5)
- L+=
- M*=
- N/=
- O1/((count * 2) ** ( 2 * count -1))
- P1/(count * 2) ** ( 2 * count -1)
- Q1/((count ** 2) * ( 2 ** count -1))
- R1/((count ** 2) ** ( 2 ** count -1))
56count = 1
sum = 0
[blank_start]while count <= 5:[blank_end]
[blank_start]sum[blank_end] [blank_start]+=[blank_end] [blank_start]1/((2 * count) ** (2 * count - 1))[blank_end]
[blank_start]count += 1[blank_end]
- Awhile count <= 5:
- Bwhile count <= 5
- Cfor count <= 5:
- Dfor count <= 5
- Esum
- Fcount
- G+=
- H^=^
- I/=
- J1/((2 * count) ** (2 * count - 1))
- K(2 * count) ** (2 * count - 1)
- L1/(2 * count) ** (2 * count - 1)
- M1/((2 ** count) * (2 ** count - 1))
- Ncount += 1
- Ocount *= 1
- Pcount /= 1
- Qcount 凸 = 凸 1
57count = 1
Ans = 0
while [blank_start]count <=5[blank_end]:
Ans [blank_start]*=[blank_end] [blank_start]1/((2 * count +1) ** (4 * count))[blank_end]
[blank_start]count += 1[blank_end]
- Acount <=5
- Bcount <=5:
- C*=
- D+=
- E1/((2 * count +1) ** (4 * count))
- F1/((4 * count +1) ** (2 * count))
- G1/((2 ** count +1) * (4 ** count))
- H1/((2 ** count) * (4 ** count + 1))
- I1/((2 * count) ** (5 * count + 1))
- Jcount += 1
- Kcount *= 1
58Ans = 0
#For loop is below
[blank_start]For count in range(1,6):[blank_end]
Ans [blank_start]*=[blank_end] [blank_start]1/((2 *count + 1) ** ( 4 * count))[blank_end]
- AFor count in range(1,6):
- BFor count in range(0,6):
- CFor count in range(6):
- DFor count in range(5):
- E*=
- F+=
- G1/((2 *count + 1) ** ( 4 * count))
- H1/(2 *count + 1) ** ( 4 * count)
- I1/((2 *count + 1) * ( 5 * count))
59Ans = 0
count = 1
while [blank_start]count <= 4[blank_end]
Ans += [blank_start]count / (count ** 2)[blank_end]
count += 1
- Acount <= 4
- Bcount <= 5
- Ccount <= 5:
- Dcount <= 4:
- Ecount / (count ** 2)
- F(count**2) / count
60Ans = 0
[blank_start]for count in range(1,6):[blank_end]
Ans [blank_start]+=[blank_end] [blank_start]count / (count ** 2)[blank_end]
- Afor count in range(1,6):
- Bfor count in range(1,6)
- Cfor count in range(0,5):
- Dfor count in range(1,5):
- Efor count in range(1,5)
- F+=
- G*=
- H凸 = 凸
- I୧༼◔益◔╭∩╮༽ 凸 ... ng lun sick ar
- Jcount / (count ** 2)
- K(count ** 2) / count
- Lcount / (count * 2)
- Mcount // (count ** 2)
61Using the len() method, write a "for" loop to display all company names from the
ProgrammeName list. Print the corresponding output, referring to the following
sample execution.
ProgrammeName = ["DSAI","GSD","SE","TN"]
for [blank_start]count[blank_end] in [blank_start]range(0,len(ProgrammeName))[blank_end]:
print(f"Programme [blank_start]{count + 1}[blank_end] :[blank_start]{ProgrammeName[count]}[blank_end]")
- Acount
- BPragrammeName
- Crange(0,len(ProgrammeName))
- Drange(0,length(ProgrammeName))
- E{count + 1}
- F(count + 1)
- G{ProgrammeName[count]}
- H(ProgrammeName[count])
62Using the len() method, write a "for" loop to display all names from the
Name list. Print the corresponding output, referring to the following
sample execution.
Name = ["Benson","Matthew","Eric","Arion"]
[blank_start]Name.sort()[blank_end]
for [blank_start]count[blank_end] in [blank_start]range(0,len(ProgrammeName))[blank_end]:
print(f"Teacher [blank_start]{count + 1}[blank_end] : [blank_start]{Name[count]}[blank_end]")
- AName.sort()
- BName.order()
- Ccount
- DName
- Erange(0,len(ProgrammeName))
- Frange(0,7)
- G{count + 1}
- H{Name[count]}
63Complete the Python program to check the Block of each Room by using the "if-elif" statement. Save the correct result into a variable named, Block.
if Room >=101 and [blank_start]Room <= 127[blank_end]:
Block = "A"
elif [blank_start]Room >= 128 and Room <= 191[blank_end]:
[blank_start]Block = "B"[blank_end]
elif Room >= 192 and [blank_start]Room <= 223[blank_end]:
[blank_start]Block = "C"[blank_end]
[blank_start]elif[blank_end] Room >= 224 and Room <= 255:
[blank_start]Block = "D"[blank_end]
- ARoom <= 127
- BRoom <= 223
- CRoom >= 128 and Room <= 191
- DBlock = "B"
- EBlock = "C"
- Felif
- GBlock = "D"
Information
- Description
- IT114126 please search!!!
- Author
- itso Lucypay
- Language
- English
- Views
- 407
- History
- Created on 24 Oct 2024 · updated on 28 Nov 2024
- Tags
- Rating
- No ratings yet Rate this quiz