Tag: Python String

  • Python Quizs Question– String II

    Q 1. What will be the output of the following Python code snippet? print(‘Ab!2’.swapcase()) A. AB!@B. ab12C. aB1@ D. aB!2 Show Answer Answer:-D. aB!2 Explanation Lowercase letters are converted to uppercase and vice-versa. Q 2. What will be the output of the following Python code snippet? print(‘ab cd ef’.title()) A. Ab cd efB. Ab cd…

You cannot copy content of this page