|
Calling function with no input argument
I had the same problem, and similarly could not find an answer online. But here it is:
Assuming you are using Matlab, you do not need the parentheses when you call the function. You defined it correctly (although you shouldn't need brackets):
function sumout = sortabc();
When you call a function with no inputs, do not use parentheses:
sumout = sortabc;
Using the same variable names shouldn't be a problem. Their domains don't overlap.
|