Top 1000+ Solved Problem Solving and Python Programming MCQ Questions Answer

From 376 to 390 of 820

Q. What is the default value of encoding in encode()?

a. ascii

b. qwerty

c. utf-8

d. utf-16

  • c. utf-8

Q. } and {1}".format('foo', 'bin'))

a. hello foo and bin

b. hello {0} and {1} foo bin

c. error

d. hello 0 and 1

  • a. hello foo and bin

Q. } and {name2}".format( 'foo', 'bin'))

a. hello foo and bin

b. hello {name1} and {name2}

c. error

d. hello and

  • c. error

Q. } and {name2}".format( name1='foo', name2='bin'))

a. hello foo and bin

b. hello {name1} and {name2}

c. error

d. hello and

  • a. hello foo and bin

Q. !r} and {0!s}".format('fo o', 'bin'))

a. hello foo and foo

b. hello ‘foo’ and foo

c. hello foo and ‘bin’

d. error

  • b. hello ‘foo’ and foo

Q. } and {1}".format(('foo', 'bin')))

a. hello foo and bin

b. hello (‘foo’, ‘bin’) and (‘foo’, ‘bin’)

c. error

d. none of the mentioned

  • c. error

Q. [0]} and {0[1]}".format(( 'foo', 'bin')))

a. hello foo and bin

b. hello (‘foo’, ‘bin’) and (‘foo’, ‘bin’)

c. error

d. none of the mentioned

  • a. hello foo and bin

Q. , 10, 12))

a. the sum of 2 and 10 is 12

b. error

c. the sum of 0 and 1 is 2

d. none of the mentioned

  • a. the sum of 2 and 10 is 12

Q. , 10, 12))

a. the sum of 2 and 10 is 12

b. the sum of 10 and a is 14

c. the sum of 10 and a is c

d. error

  • b. the sum of 10 and a is 14

Q. 2223334))

a. 1,112,223,334

b. 111,222,333,4

c. 1112223334

d. error

  • a. 1,112,223,334

Q. 2223334'))

a. 1,112,223,334

b. 111,222,333,4

c. 1112223334

d. error

  • d. error

Q. 2223334))

a. 1,112,223,334

b. 111,222,333,4

c. 1112223334

d. error

  • d. error

Q. 2223334))

a. 1,112,223,334

b. 111,222,333,4

c. 1112223334

d. error

  • c. 1112223334

Q. :.2}'.format(1/3))

a. 0.333333

b. 0.33

c. 0.333333:.2

d. error

  • b. 0.33

Q. :.2%}'.format(1/3))

a. 0.33

b. 0.33%

c. 33.33%

d. 33%

  • c. 33.33%
Subscribe Now

Get All Updates & News