Swap function calling

In this program there are 2 functions named Swap. How does the program recognize which Swap function to use when Swap is called. Does it recognize with the help of parameters or is it something else?

yes it recognizes it with the help of

  1. no of parameters
  2. type of parameters
  3. return type
    This is called run time polymorphism