HOW MANY WAYS CAN AN ARGUMENT BE PASSED TO A SUBROUTINE AND EXPLAIN THEM?

Pushpendra Singh

Total Post:240

Points:1200
Posted by  Pushpendra Singh
Java 
 1171  View(s)
Ratings:
Rate this:
  1. Pushpendra Singh

    Post:240

    Points:1200
    How many ways can an argument be passed to a subroutine and explain them?

    An argument can be passed in two ways. They are passing by value and passing by reference.

    Passing by value: This method copies the value of an argument into the formal parameter of the subroutine.
    Passing by reference: In this method, a reference to an argument (not the value of the argument) is passed to the parameter.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!