16/16 Help?


#1

It is not printing my code?
Here are the directions for the task:

On line 3, create the variable my_string and set it to any string you'd like.
On line 4, print the length of my_string.
On line 5, print the .upper() case version of my_string.

and here is my code:

my_string = "Hello!"
print my_string.length
print my_string.upper()

Any help is great! Thank you


#2

Hi,
I think you misunderstood the instruction at this point ^^

Because

won't work :frowning:

You have to type len(my_string) to get the length of your string (.length doen't exist) :grin:
-> Strings & Console Output (5. String methods) :wink:

So re-type the line as:

print len(my_string)

#3

I think he was trying a Javascript term :smiley:

No worries systemslayer97639, just re-write that little bit.

This should be
print len(my_string)