commited all contents created by participants

This commit is contained in:
Bachir Soussi Chiadmi
2017-12-21 18:12:40 +01:00
parent cefd1c2ad0
commit b936b1e616
2137 changed files with 1076319 additions and 730 deletions
+36
View File
@@ -0,0 +1,36 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
# Write sentence as string
sentence = "Je vois La Vie en rose... Tu vois Le Ciel en vert!"
# Print sentence
print("phrase originale:", sentence)
# Convert sentence in one word (remove spaces)
#one_word = sentence.strip(" ")
#print("sans les espaces:", one_word)
# define new word as list
new_word = []
# Convert sentence in list of words
words = sentence.split()
#print(words)
# For each word in word list
for word in words:
# remove capital letters (string operation)
#word = word.lower()
# Clean punctuation (string operation)
#word = word.strip(" ;''?:,()!.\").”-")
# add word to new word list
new_word.append(word)
#new_letter = []
#letter = words.split()
#print(letter)
# Write words as one, without spaces
print("phrase sans espaces:", "".join(new_word))