mirror of
				https://gitlab.com/klmp200/LO27.git
				synced 2025-10-31 08:23:04 +00:00 
			
		
		
		
	Ajout de OR et AND
This commit is contained in:
		| @@ -137,3 +137,19 @@ void FreeCellElement(cellElement* element) { | ||||
| 	element = NULL; | ||||
| } | ||||
|  | ||||
|  | ||||
| bool OR(bool a, bool b){ | ||||
| 	if (a || b){ | ||||
| 		return true; | ||||
| 	} else { | ||||
| 		return false; | ||||
| 	} | ||||
| } | ||||
|  | ||||
| bool AND(bool a, bool b){ | ||||
| 	if (a && b){ | ||||
| 		return true; | ||||
| 	} else { | ||||
| 		return false; | ||||
| 	} | ||||
| } | ||||
|   | ||||
| @@ -144,4 +144,21 @@ int SetNextRow(cellElement* tree,cellElement* elem); | ||||
|  | ||||
| void recursivePrint(cellElement * tree); | ||||
|  | ||||
|  | ||||
| /** | ||||
| * Apply OR operator to a bool a and a bool b | ||||
| * @param a a bool | ||||
| * @param b a bool | ||||
| * @return result a or b | ||||
| */ | ||||
| bool OR(bool a, bool b); | ||||
|  | ||||
| /** | ||||
| * Apply AND operator to a bool a and a bool b | ||||
| * @param a a bool | ||||
| * @param b a bool | ||||
| * @return result a and b | ||||
| */ | ||||
| bool AND(bool a, bool b); | ||||
|  | ||||
| #endif | ||||
|   | ||||
| @@ -311,7 +311,6 @@ Matrix freeMatrix(Matrix matrix){ | ||||
| } | ||||
|  | ||||
|  | ||||
|  | ||||
| /* todos : | ||||
| *finir le freeMatrix | ||||
| *chasser les bugs | ||||
|   | ||||
		Reference in New Issue
	
	Block a user