Question: ( 2 0 points ) What will be the output of the following code if the user enters: a ) hello b ) hi

(20 points) What will be the output of the following code if the user enters:
a) "hello"
b)"hi"
c)"CS 104 is fun"
d) "bye"
def mystery(text):
y=0
new_text =""
for i in range(text):
if i==1 :
y+=1
if i8 :
break
else:
new_text = new_text + str (i)
y+=1
print (y)
return new_text
text = input ()
if len(text)>4:
output = mystery text
 (20 points) What will be the output of the following code

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!