passing by reference and value