Tokenize a string: Difference between revisions
Content deleted Content added
Python version |
|||
Line 27: | Line 27: | ||
for word in words: |
for word in words: |
||
print word |
print word |
||
This prints each word on its own line. If we want to follow the task specification strictly, we join the array elements with a dot, then print the resulting string: |
|||
print '.'.join("Hello,How,Are,You,Today".split(',')) |
|||
==[[Ruby]]== |
==[[Ruby]]== |