I'm developing a bunch of functions that have the same basic structure - they take two lists and use a loop to do a particular operation pairwise for the two lists (for example, one will take each element of a list raised to the power represented by the corresponding element in the second list).
Since all of these function differ only by an operator, I was wondering - is it possible to set a variable to an operator? For example, can you do (something similar to):
var = +
var2 = 5 var 7 #var2 is now 12
I know that specifically doesn't work, but is there anything similar that does work similarly?