An object can be used as a function argument. This can be done in two ways.

i) Pass by value: A copy of an entire object is passed to the function, so any changes made to the object inside the function do not affect the object  used to call the function.

ii) Pass by reference: Only the address of the object is transferred to the function. When an address of the object is passed, the called function works directly on the actual object used in the call. This means that any changes made to the object inside the function will reflect the actual object.

The pass by reference method is more efficient since it requires to pass only address of the object and not the entire object.