mirror of
https://gitlab.com/klmp200/LO27.git
synced 2024-11-26 03:44:15 +00:00
Ajout de OR et AND
This commit is contained in:
parent
85872acc6e
commit
b063bc42c0
@ -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
|
||||
|
Loading…
Reference in New Issue
Block a user