From fe32ade285c49dd7fd16915aa9923a392b417a2e Mon Sep 17 00:00:00 2001 From: Camille Chauvet Date: Mon, 7 Aug 2023 16:57:03 +0200 Subject: [PATCH] remove com --- ex02/src/main.cpp | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/ex02/src/main.cpp b/ex02/src/main.cpp index 62961ec..8d57f0f 100644 --- a/ex02/src/main.cpp +++ b/ex02/src/main.cpp @@ -14,50 +14,39 @@ int main( void ) { std::cout << Fixed::max( a, b ) << std::endl; } { - // Créer deux objets Fixed pour les tests const Fixed a(2.5f); const Fixed b(1.3f); std::cout << "b: " << a << std::endl; std::cout << "a: " << b << std::endl; - // Test de l'opérateur d'addition (+) Fixed sum = a + b; std::cout << "Addition: " << sum << std::endl; - - // Test de l'opérateur de soustraction (-) - Fixed difference = a - b; + + Fixed difference = a - b; std::cout << "Subtraction: " << difference << std::endl; - // Test de l'opérateur de multiplication (*) Fixed product = a * b; std::cout << "Multiplication: " << product << std::endl; - // Test de l'opérateur de division (/) Fixed quotient = a / b; std::cout << "Division: " << quotient << std::endl; - // Test de l'opérateur de comparaison (==) bool isEqual = (a == b); std::cout << "Is a equal to b? " << std::boolalpha << isEqual << std::endl; - // Test de l'opérateur de comparaison (!=) bool isNotEqual = (a != b); std::cout << "Is a not equal to b? " << std::boolalpha << isNotEqual << std::endl; - // Test de l'opérateur de comparaison (<) bool isLessThan = (a < b); std::cout << "Is a less than b? " << std::boolalpha << isLessThan << std::endl; - // Test de l'opérateur de comparaison (>) bool isGreaterThan = (a > b); std::cout << "Is a greater than b? " << std::boolalpha << isGreaterThan << std::endl; - // Test de l'opérateur de comparaison (<=) bool isLessThanOrEqual = (a <= b); std::cout << "Is a less than or equal to b? " << std::boolalpha << isLessThanOrEqual << std::endl; - // Test de l'opérateur de comparaison (>=) bool isGreaterThanOrEqual = (a >= b); std::cout << "Is a greater than or equal to b? " << std::boolalpha << isGreaterThanOrEqual << std::endl; }