You can do everything in a sub that you could in a function EXCEPT that you cant return anything back.
In your examples,
If C is a variable, it works for both function and sub and i think neither function nor sub will work if you put some constant like '1' in arguments list which is absolutely of no use.
In your examples,
If C is a variable, it works for both function and sub and i think neither function nor sub will work if you put some constant like '1' in arguments list which is absolutely of no use.