Manipulating String

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

cde

What is the output for the following code? Enter the result in the blank. >>> num = "abcdefghi" >>> num[2:5]

7

What is the output of the following program? >>> phrase = "help me" >>> len(phrase)

False

What is the output? >>> password = "sdf#_356" >>> password.isalnum()

False

What is the output? >>> password = "sdf345" >>> password.isalpha()

sentence[2:5]

>>> sentence = "Programming is fun!" >>> _____ 'ogr'

answer.capitalize()

What is the missing line of code? >>> answer = "happy birthday" >>> _____ 'Happy birthday'

sentence[3:5]

What is the missing line of code? >>> sentence = "Programming is fun!" >>> _____ 'gr'

sentence[3:6]

What is the missing line of code? >>> sentence = "Programming is fun!" >>> _____ 'gra'

hello dad

What is the output for the following code? >>> answer = "Hello Dad" >>> answer.lower()

True

What is the output for the following code? >>> phrase = "help23" >>> phrase.isalnum()

answer = "23" answer = input("How old are you? ") answer = '23'

Which of the following shows the assignment of a string to a variable? Select 3 options.


संबंधित स्टडी सेट्स

Score for this attempt: 0 out of 100 Submitted Feb 6 at 2:57pm This attempt took 30 minutes. UnansweredQuestion 1 0 / 5 pts A Trojan is a malicious program that uses a computer network to replicate. False True A worm is a malicious program that us

View Set

Micro final from previous quizzes

View Set

FAR Chapter 18 - Preffered Stock and Common Stock

View Set

Chapter 55: Care of Patients with Stomach Disorders (H)

View Set

Chapter 3: Historical Foundations of Professional Nursing

View Set