← Previous Next →

Characters counting

Created by Julien Palard

Instructions

Print the number of characters in the given paragraph.

I prefilled the answer box with the paragraph, and assigned it the name phantom_menace.

Just in case you loose it, here it is, so you can copy/paste it:

phantom_menace = """Turmoil has engulfed the Galactic Republic. The
taxation of trade routes to outlying star systems is in
dispute. Hoping to resolve the matter with a blockade of deadly
battleships, the greedy Trade Federation has stopped all shipping to
the small planet of Naboo. While the congress of the Republic
endlessly debates this alarming chain of events, the Supreme
Chancellor has secretly dispatched two Jedi Knights, the guardians of
peace and justice in the galaxy, to settle the conflict"""

Advice

If you feel lost, you should start by reading the string tutorial.

You don't have to edit line 1-12, write your code below the # Enter your code below: comment and don't forget to use the print function to print the result!

Also take a look at the len function.

Don't hesitate to click the Run button just to execute your code so you can experiment like if it's on your computer, the result is displayed on the right column, and when you're done, click the Submit for validation button so the correction bot can take a look at it.

Your Code

Login to check your code and save your progress.