Explanation: typeerror, the fill character must be a character, not an int.
Problem Solving and Python Programming MCQs | Page - 19
Dear candidates you will find MCQ questions of Problem Solving and Python Programming here. Learn these questions and prepare yourself for coming examinations and interviews. You can check the right answer of any question by clicking on any option or by clicking view answer button.
Explanation: the character ‘1’ is used for padding instead of a space.
Explanation: the fill character must be exactly one character long.
Explanation: counts the number of times the substring ‘xyy’ is present in the given string, starting from position 2 and ending at position 11.
Explanation: the default value of encoding is utf-8.
Explanation: the numbers 0 and 1 represent the position at which the strings are present.
Explanation: the numbers 0 and 1 represent the position at which the strings are present.
Explanation: the arguments passed to the function format aren’t keyword arguments.
Explanation: !r causes the characters ‘ or ” to be printed as well.
Explanation: indexerror, the tuple index is out of range.
Jump to