marina-maths 1.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,58 @@
1
+ Metadata-Version: 2.4
2
+ Name: marina-maths
3
+ Version: 1.0.0
4
+ Summary: Package de calcul mathematique avec menu interactif
5
+ Author: Marina
6
+ Description-Content-Type: text/markdown
7
+ Dynamic: author
8
+ Dynamic: description
9
+ Dynamic: description-content-type
10
+ Dynamic: summary
11
+
12
+ # Marina Maths Calculator
13
+
14
+ ## Auteur
15
+
16
+ Marina
17
+
18
+ ## Version
19
+
20
+ 1.0.0
21
+
22
+ ## Description
23
+
24
+ Marina Maths Calculator est un package Python permettant
25
+ d'effectuer des calculs mathématiques à partir d'un menu
26
+ interactif personnalisé.
27
+
28
+ ## Fonctionnalités
29
+
30
+ - Saisie du nom de l'utilisateur
31
+ - Addition
32
+ - Soustraction
33
+ - Multiplication
34
+ - Division
35
+ - Puissance
36
+ - Racine carrée
37
+ - Moyenne
38
+ - Minimum
39
+ - Maximum
40
+ - Gestion des erreurs
41
+
42
+ ## Installation
43
+
44
+ ```bash
45
+ pip install --index-url https://test.pypi.org/simple/ --no-deps marina-maths
46
+ ```
47
+
48
+ ## Utilisation
49
+
50
+ ```python
51
+ from mon_package import menu
52
+
53
+ menu()
54
+ ```
55
+
56
+ ## Remerciements
57
+
58
+ Merci d'utiliser Marina Maths Calculator.
@@ -0,0 +1,47 @@
1
+ # Marina Maths Calculator
2
+
3
+ ## Auteur
4
+
5
+ Marina
6
+
7
+ ## Version
8
+
9
+ 1.0.0
10
+
11
+ ## Description
12
+
13
+ Marina Maths Calculator est un package Python permettant
14
+ d'effectuer des calculs mathématiques à partir d'un menu
15
+ interactif personnalisé.
16
+
17
+ ## Fonctionnalités
18
+
19
+ - Saisie du nom de l'utilisateur
20
+ - Addition
21
+ - Soustraction
22
+ - Multiplication
23
+ - Division
24
+ - Puissance
25
+ - Racine carrée
26
+ - Moyenne
27
+ - Minimum
28
+ - Maximum
29
+ - Gestion des erreurs
30
+
31
+ ## Installation
32
+
33
+ ```bash
34
+ pip install --index-url https://test.pypi.org/simple/ --no-deps marina-maths
35
+ ```
36
+
37
+ ## Utilisation
38
+
39
+ ```python
40
+ from mon_package import menu
41
+
42
+ menu()
43
+ ```
44
+
45
+ ## Remerciements
46
+
47
+ Merci d'utiliser Marina Maths Calculator.
@@ -0,0 +1,58 @@
1
+ Metadata-Version: 2.4
2
+ Name: marina-maths
3
+ Version: 1.0.0
4
+ Summary: Package de calcul mathematique avec menu interactif
5
+ Author: Marina
6
+ Description-Content-Type: text/markdown
7
+ Dynamic: author
8
+ Dynamic: description
9
+ Dynamic: description-content-type
10
+ Dynamic: summary
11
+
12
+ # Marina Maths Calculator
13
+
14
+ ## Auteur
15
+
16
+ Marina
17
+
18
+ ## Version
19
+
20
+ 1.0.0
21
+
22
+ ## Description
23
+
24
+ Marina Maths Calculator est un package Python permettant
25
+ d'effectuer des calculs mathématiques à partir d'un menu
26
+ interactif personnalisé.
27
+
28
+ ## Fonctionnalités
29
+
30
+ - Saisie du nom de l'utilisateur
31
+ - Addition
32
+ - Soustraction
33
+ - Multiplication
34
+ - Division
35
+ - Puissance
36
+ - Racine carrée
37
+ - Moyenne
38
+ - Minimum
39
+ - Maximum
40
+ - Gestion des erreurs
41
+
42
+ ## Installation
43
+
44
+ ```bash
45
+ pip install --index-url https://test.pypi.org/simple/ --no-deps marina-maths
46
+ ```
47
+
48
+ ## Utilisation
49
+
50
+ ```python
51
+ from mon_package import menu
52
+
53
+ menu()
54
+ ```
55
+
56
+ ## Remerciements
57
+
58
+ Merci d'utiliser Marina Maths Calculator.
@@ -0,0 +1,9 @@
1
+ README.md
2
+ setup.py
3
+ marina_maths.egg-info/PKG-INFO
4
+ marina_maths.egg-info/SOURCES.txt
5
+ marina_maths.egg-info/dependency_links.txt
6
+ marina_maths.egg-info/top_level.txt
7
+ mon_package/__init__.py
8
+ mon_package/math_utils.py
9
+ mon_package/menu.py
@@ -0,0 +1 @@
1
+ mon_package
@@ -0,0 +1 @@
1
+ from .menu import menu
@@ -0,0 +1,30 @@
1
+ import math
2
+
3
+ def addition(a, b):
4
+ return a + b
5
+
6
+ def soustraction(a, b):
7
+ return a - b
8
+
9
+ def multiplication(a, b):
10
+ return a * b
11
+
12
+ def division(a, b):
13
+ if b == 0:
14
+ raise ValueError("Division par zéro impossible")
15
+ return a / b
16
+
17
+ def puissance(a, b):
18
+ return a ** b
19
+
20
+ def racine_carree(a):
21
+ return math.sqrt(a)
22
+
23
+ def moyenne(liste):
24
+ return sum(liste) / len(liste)
25
+
26
+ def minimum(liste):
27
+ return min(liste)
28
+
29
+ def maximum(liste):
30
+ return max(liste)
@@ -0,0 +1,107 @@
1
+ from . import math_utils
2
+
3
+ def menu():
4
+
5
+ print("==MARINA MATHS CALCULATOR==")
6
+
7
+
8
+ nom = input("Entrez votre nom : ")
9
+
10
+ print("\nBienvenue", nom, "dans notre calculatrice !")
11
+
12
+ while True:
13
+
14
+ print("Faites un choix")
15
+ print("1. Addition")
16
+ print("2. Soustraction")
17
+ print("3. Multiplication")
18
+ print("4. Division")
19
+ print("5. Puissance")
20
+ print("6. Racine carrée")
21
+ print("7. Moyenne")
22
+ print("8. Minimum")
23
+ print("9. Maximum")
24
+ print("0. Quitter")
25
+
26
+ choix = input(nom + ", entrez votre choix : ")
27
+
28
+ try:
29
+
30
+ if choix == "1":
31
+
32
+ a = float(input("Premier nombre : "))
33
+ b = float(input("Deuxième nombre : "))
34
+
35
+ resultat = math_utils.addition(a, b)
36
+
37
+ elif choix == "2":
38
+
39
+ a = float(input("Premier nombre : "))
40
+ b = float(input("Deuxième nombre : "))
41
+
42
+ resultat = math_utils.soustraction(a, b)
43
+
44
+ elif choix == "3":
45
+
46
+ a = float(input("Premier nombre : "))
47
+ b = float(input("Deuxième nombre : "))
48
+
49
+ resultat = math_utils.multiplication(a, b)
50
+
51
+ elif choix == "4":
52
+
53
+ a = float(input("Premier nombre : "))
54
+ b = float(input("Deuxième nombre : "))
55
+
56
+ resultat = math_utils.division(a, b)
57
+
58
+ elif choix == "5":
59
+
60
+ a = float(input("Entrez la base : "))
61
+ b = float(input("Entrez l'exposant : "))
62
+
63
+ resultat = math_utils.puissance(a, b)
64
+
65
+ elif choix == "6":
66
+
67
+ a = float(input("Entrez un nombre : "))
68
+
69
+ resultat = math_utils.racine_carree(a)
70
+
71
+ elif choix == "7":
72
+
73
+ valeurs = input("Entrez les nombres séparés par des espaces : ")
74
+ liste = [float(x) for x in valeurs.split()]
75
+
76
+ resultat = math_utils.moyenne(liste)
77
+
78
+ elif choix == "8":
79
+
80
+ valeurs = input("Entrez les nombres séparés par des espaces : ")
81
+ liste = [float(x) for x in valeurs.split()]
82
+
83
+ resultat = math_utils.minimum(liste)
84
+
85
+ elif choix == "9":
86
+
87
+ valeurs = input("Entrez les nombres séparés par des espaces : ")
88
+ liste = [float(x) for x in valeurs.split()]
89
+
90
+ resultat = math_utils.maximum(liste)
91
+
92
+ elif choix == "0":
93
+
94
+ print("Merci", nom, "pour votre visite !")
95
+ print("À bientôt !")
96
+ break
97
+
98
+ else:
99
+
100
+ print("Choix invalide. Réessayez.")
101
+ continue
102
+
103
+ print(nom + ", votre résultat est :", resultat)
104
+
105
+ except (ValueError, ArithmeticError):
106
+
107
+ print("Erreur : veuillez entrer des valeurs valides.")
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,11 @@
1
+ from setuptools import setup, find_packages
2
+
3
+ setup(
4
+ name="marina-maths",
5
+ version="1.0.0",
6
+ author="Marina",
7
+ description="Package de calcul mathematique avec menu interactif",
8
+ packages=find_packages(),
9
+ long_description=open("README.md", encoding="utf-8").read(),
10
+ long_description_content_type="text/markdown"
11
+ )