Last active
March 11, 2016 19:15
-
-
Save lovasoa/e196c2e918a84abddead to your computer and use it in GitHub Desktop.
Application du fameux pythonnist Alexis
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
a=0 | |
ch=input("indiquez votre année : ") | |
a=float(ch) | |
if (a%4==0) & (a%100!=0): | |
print("l'année est bissextile") | |
elif a%400==0: | |
print("l'année est quand meme bissextile") | |
else: | |
print("perdu,cette année n'est pas bissextile") | |
genre = input("veuillez donner votre genre (F ou M) :") | |
nom = input("votre nom maintenant :") | |
if genre=="M": | |
suffixe = "" | |
appel = "monsieur" | |
else: | |
suffixe = "e" | |
appel = "madame" | |
print("Bonjour cher"+suffixe+" "+appel+" "+nom+" !") | |
i=input("quelle note sur 120 avez-vous obtenue? :") | |
a=float(i) | |
b=120 | |
c=a/b | |
if c>=80/100: | |
print("votre mention est:","A", "c'est très bien Monsieur Lojkine") | |
elif 60/100<=c<80/100: | |
print("votre mention est:","B","pas mal Ophir") | |
else: | |
print("mais vous êtes nul " + appel + " " + nom) | |
z=[] | |
a=1 | |
while a>0: | |
print("entre une note positive, quand tu auras fini de remplir tes notes, rentre\ | |
-1 pour passer à la suite") | |
ch=input() | |
a=float(ch) | |
if a>0: | |
z.append(a) | |
print(z) | |
c=0 | |
if a<=0: | |
c=sum(z)/len(z) | |
print("votre moyenne est :",c, "peut mieux faire Monsieur Lojkine") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment