Learn

Great job! You’ve learned a lot in this unit, including:

Three ways to create strings

'Alpha' "Bravo" str(3)

String methods

len("Charlie") "Delta".upper() "Echo".lower()

Printing a string

print "Foxtrot"

Advanced printing techniques

g = "Golf" h = "Hotel" print "%s, %s" % (g, h)

Instructions

1.

Let’s wrap it all up!

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

Take this course for free

Mini Info Outline Icon
By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.

Or sign up using:

Already have an account?