-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtraduction.py
More file actions
27 lines (19 loc) · 913 Bytes
/
traduction.py
File metadata and controls
27 lines (19 loc) · 913 Bytes
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
#-*- coding: utf-8 -*-
### En python
###
## Traduction
## CONDITIONS
if 1 < 4: # 'if' ça veut dire "si"
print("Plus petit") # 'print' ça veut dire "afficher"
else: # 'else' ça veut dire "autrement"
print("Plus grand")
resultat = raw_input("Quel est ton nom ?") # 'raw_input' ça veut dire affiche "Quel est on nom" puis attend que l'utilisateur
# tape quelque chose pour répondre. Quand il a fini il doit appuyer sur Entrée
# ce qu'il a écrit est dans 'resultat'
print("Tu t'appelles..."+resultat)
## BOUCLES, LES REPETITIONS
for i in range(0, 2): # on répète dans l'interval (0,10) quelque chose.
print("Bonjour papa")
for i in range(0, 2):
print("BONJOUR PAPA")
nom = ra