• API
• FAQ
• Tools
• Archive
SHARE
TWEET

# Untitled

zeeph Jan 9th, 2019 57 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
1. #Trouver les taux compris entre 3% et 12%
2. result = []
3. liste = [0.01, 0.03, 0.11, 0.55]
4.
5. for a in liste:
6.     if a*100>3 and a*100<12:
7.         result.append(a)
8.
9. print(result)
10.
11.
12.
13.
14. #Permuter a,b,c
15. a = 1
16. b = 2
17. c = 3
18. temp = 0
19.
20. temp = c #d = 3
21. b = 1 #b = 1
22. c = 2 #c = 3
23. a = 3
24.
25. print(a,b,c)
26.
27. #Manière rapide
28. a, b, c = c , a, b
29.
30. print(a,b,c)
31.
32.
33.
34. #Afficher les tables de multiplications de 1 à 10
35. for a in range(1,11):
36.         result = []
37.         for b in range(1,11):
38.                 result.append(a*b)
39.         print(result)
40.
41.
42. #Le jeu du loto
43. import random
44. for a in range(1,8):
45.         print (random.randint(1,51)) #Générer un nombre alléatoire entre 1 et 51
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy.

Top