1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
|
mot = input("Entrez votre mot (pas plus de trois lettres) ")
langue = input ("A quel langue correspond t-il ? (donnez en une)(Fr= Français, Ang= Anglais, Esp= Espagnol, All= Allemand)")
OuiOuNon = input("Correspond t-il a une autre langue? (oui/non)")
while OuiOuNon != 'non':
langue = input('A quel autre langue appartient-il? (entrez en une)(Fr= Français, Ang= Anglais, Esp= Espagnol, All= Allemand)')
OuiOuNon = input("Correspond t-il a une autre langue? (oui/non)")
import csv
with open('BDM.csv','w+',newline='') as fichiercsv:
writer=csv.writer(fichiercsv)
writer.writerow(['Mots','Français','Anglais','Espagnol','Allemand'])
def AjouterLangue():
import csv
with open('BDM.csv','a',newline='',encoding='utf-8') as fichiercsv:
writer=csv.writer(fichiercsv)
writer.writerow([mot])
# if langue == 'Fr':
#if langue == 'Ang':
# if langue == 'Esp':
# if langue == 'All':
AjouterLangue() |
Partager