samedi 9 janvier 2021

Turning a multiple argumented if function with (or and) logic gates into a numpy function

How could I turn function with the format of if((arg[1] or arg[2]) and (arg[3] or arg[4]) and arg[5])): into a numpy function. arg[1] is meant to be argument 1 and arg[2] is meant to be for argument 2 and so on. So if either of arg[1], arg[2] returns true, either arg[3], arg[4] returns true and arg[5] returns true then the if function will execute.

Aucun commentaire:

Enregistrer un commentaire