Créer jeu
Télécharger
Obtenir Plan Académique
Partager le jeu
Intégrez-le à votre plateforme

Vous pouvez intégrer le jeu dans un LMS compatible avec LTI 1.1 ou LTI 1.3 comme Canvas, Moodle ou Blackboard. Les scores seront ainsi automatiquement enregistrés dans le carnet de notes de la plateforme.
Télécharger
Vous avez dépassé le nombre maximum de jeux que vous pouvez intégrer à Google Classroom avec votre Plan actuel.

Pour intégrer autant de jeux que vous le souhaitez dans Google Classroom, vous avez besoin d’un Plan Académique ou un Plan Commerciel.

Vous avez dépassé le nombre maximum de jeux que vous pouvez intégrer à Microsoft Teams avec votre Plan actuel.

Pour intégrer autant de jeux que vous le souhaitez dans Microsoft Teams, vous avez besoin d’un Plan Académique ou un Plan Commerciel.

Le téléchargement du jeu est une fonctionnalité exclusive pour les utilisateurs avec un Plan Académique ou un Plan Commercial.

Obtenez votre Plan Académique ou Plan Commercial dès maintenant et commencez à intégrer vos jeux dans votre LMS, votre site Web ou votre blog.

Si vous le souhaitez, vous pouvez télécharger une jeu de test ici et tester son intégration:

Pure Python code

Test

Parties jouées 1

À propos de cette activité

Test your knowledge of pure Python code

Créé par

Spain

Téléchargez la version pour jouer sur papier

Créez votre propre jeu gratuite à partir de notre créateur de jeu
Affrontez vos amis pour voir qui obtient le meilleur score dans ce jeu

Top Jeux

%
Anonyme
Anonyme
%
%
%
Vous avez dépassé le nombre maximum de jeux que vous pouvez imprimer avec votre Plan actuel.

Pour imprimer autant de jeux que vous le souhaitez, vous avez besoin d’un Plan Académique ou un Plan Commerciel.

Imprimez votre jeu
Pure Python code
 

Pure Python codeVersion en ligne

Test your knowledge of pure Python code

par Álvaro Manuel Navarro Cruz
1

Which line is not correct? Pay attention to the indentation.

2

Is this correct if we want to generate a random number between 1 and 100?

3

Is it necessary to specify the last "elif" condition?

4

Which of the following statements about the filterEvenNumbers() function are correct?

Choose one or more answers

5

What is the purpose of the while loop in the timesTable program?

Feedback

If we leave line 5 in place, the if condition will be empty.

The function random.randint(a, b) generates a random integer including both endpoints a and b. So, random.randint(1, 98) will only generate numbers from 1 up to 98, excluding 99 and 100.

Using else here simplifies the code because all other possibilities have been eliminated by previous checks (if and elif). Since the only remaining case is that the number is equal, else handles it cleanly and reduces redundancy. This approach is common and accepted in programming to keep the code concise.

The while loop in the timesTable program is designed to repeatedly prompt the user to enter numbers and print the corresponding multiplication tables. The loop continues executing as long as the user does not enter the sentinel value -1. When the user inputs -1, the loop terminates, effectively stopping the repetition of multiplication tables. This allows the program to keep running and displaying new tables for different numbers until the user decides to stop by typing -1. Therefore, the purpose of the while loop is to keep printing multiplication tables until the user types -1.

Voulez-vous vraiment quitter la page ?

Si vous partez, vous perdrez la partie en cours.