Commit bd1d8186 authored by bcontreras's avatar bcontreras

Fix replace so that 1st , and 2nd . chars are replaced

parent 23222893
Pipeline #16302 passed with stage
in 20 seconds
......@@ -1537,7 +1537,7 @@ long_string = """
This is the tale of a tiny snail, and a great big, grey blue, humpback whale. This is a rock, as black as soot, and this is a snail with an itchy foot.
The sea snail slithered all over the rock, and gazed at the sea and the ships in the dock.
"""
word_counts = Counter(long_string.replace(',','').replace(',','').lower().split())
word_counts = Counter(long_string.replace(',','').replace('.','').lower().split())
print(word_counts['this'])
~~~
{: .language-python }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment