python method as argument
<p>So I know in python everything is an 'object' meaning that it can be passed as an argument to a method. But I'm trying to understand how exactly does this work. So I was trying out the following example:</p>

<pre><code>class A:

    def __init__(self):
        self.value = 'a'

    def my_method(self)
        print self.value

class B:

   def __init__(self):
       self.values = 'b'

   def my_method(self, method):
       method()

a = A()
b = B()
b.my_method(a.my_method)
</code></pre>

<p>Now first this was written just to see how things work. I know I should for example check if <code>my_method</code> 's argument is callable. Now my question is:</p>

<p>How exactly is the method passed here? I mean the output I'm recieving is 'a' so I'm guessing that when a object method is passed as parameter so is the actual object ? In this case when I pass <code>a.my_method</code> the instance <code>a</code> is also passed ?       </p>
