This question already has an answer here:
I have been met with the following problem:
I have defined the following:
That means, if I call:
The output of the program is going to be simply:
Now, I would like to do the following:
e > 0, do something. If
e <= 0, output
myFunc, just like in the previous example. How would I go about doing this?
I was thinking about something like this, but I have no idea what to put in the last argument of the If function.
myFunc[e_Integer] := If[e>0, e*e , (* ? *) ];
Any responses would be greatly welcome.