I\'m a beginner C programmer, and I assumed that this would be the case, but would like some affirmation if possible.
If they are the same, why not just take one arg
There is a slight distinction: Calloc can decide to zero-out the memory only as it is needed and then there's the advantage of knowing the size of the elements.
I can't name any implementations doing this, but it was thought for this.
As an example:
One callocates 4GB of memory, but the system has only 2GB: it wouldn't make sense to write 2GBs of zero into the virtual memory, therefore the system could set a dirty-flag on this memory to zero it out as it gets loaded into memory.