python OOP, accessing attributes
<p>Why do i get an "AttributeError: 'NewOne' object has no attribute 'self.b'" error message when i try to access the attribute 'self.b' from the NewOne class. I mean it's right there. </p>

<pre><code>class NewOne(object):  
    def __init__(self):
        self.b = 'Cat' # this is what i want to access
    def child(self):
        self.c = 'kitten'
        return self.c

class FatherClass(object):
    def __init__(self, a):
        self.a = a
    def son(self):
        self.i = 'I and my father'
        return self.i
    def father(self):
        self.x = 'are one'
        return self.x
    def father_son(self):
        u = NewOne()
        k = getattr(u, 'self.b') #why does it tell me NewOne has no self.b attr
        return self.a, k()
</code></pre>

<p>Isn't getattr used to access a method? Why is it called getattr and not getmeth or something?
Thanks</p>
