Your last idea will work, but you have to repeat code.

A list of operations in your sample program would be simplistic. You submitted add and multiply in the command line arguments. Build it into a list.... pseudo-pseudocode:

Code:
list = {add, multiply}

var single = 0

foreach item of list
	single = do_operation(item);
	print single
end foreach
The do_operation() function could be a function containing one switch statement that does only one operation, based upon the current operation. TBH, you don't even need a real function. You could just stick your switch statement right there, and compute the value of one operation and put that in single.

The real work would be on building the actual list of operations. Then all you would have to do would be to cycle through them all in a loop. You could create another variable named final that should contain the value of all of the operations combined as you go through this loop. That way you just have to iterate through the loop once and print final when finished.