Vrai/Faux : Variables Python (niveau 1)
Créez un compte gratuit pour suivre votre avancement et reprendre où vous avez laissé.
Créer un compteObjectifs travaillés
Pour chaque affirmation suivante sur les variables et leurs types en Python, indiquez si elle est Vraie ou Fausse.
Déroulement pas à pas (Correction et Indices)
Question 1 : On exécute l'instruction Python suivante :
a = 5
Affirmation : Cette instruction teste si a est égal à $5$.
a = 5- (Incorrect) Vrai
- (Correct) Faux
Question 2 : Affirmation : L'instruction type(3.14) renvoie class 'float'.
- (Correct) Vrai
- (Incorrect) Faux
Question 3 : Affirmation : Le nom de variable 1variable est valide en Python.
- (Incorrect) Vrai
- (Correct) Faux
Question 4 : On exécute le programme Python ci-dessous :
a = "7"
Affirmation : Après cette instruction, la variable a est de type int (entier).
a = "7"- (Incorrect) Vrai
- (Correct) Faux
Question 5 : Affirmation : Le nom de variable ma_variable est valide en Python.
- (Correct) Vrai
- (Incorrect) Faux
Question 6 : Affirmation : En Python, MaVariable et mavariable désignent deux variables différentes.
- (Correct) Vrai
- (Incorrect) Faux