How to reference a class that is not inherited
<p>I have 2 classes, a robot class to move units and a map class to keep track of where they are. There is one atlas class and multiple robot classes in a atlas. How can i use a function in Atlas from class Robot.</p>

<pre><code>class Atlas:
    def __init__(self):
        self.robots = []
        self.currently_occupied = {}

    def add_robot(self, robot):
        self.robots.append(robot)
        self.currently_occupied = {robot:[]}   

    def all_occupied(self):
        return self.currently_occupied

    def occupy_spot(self, x, y, name):
        self.currently_occupied[name] = [x, y]


class Robot():
    def __init__(self, rbt):
        self.xpos = 0
        self.ypos = 0
        atlas.add_robot(rbt)  #&lt;-- is there a better way than explicitly calling this atlas
        self.name = rbt

    def step(self, axis):
        if axis in "xX":
            self.xpos += 1 
        elif axis in "yY":
            self.ypos += 1
        atlas.occupy_spot(self.xpos, self.ypos, self.name)

    def walk(self, axis, steps=2):
        for i in range(steps):
            self.step(axis)



atlas = Atlas()  #&lt;--  this may change in the future from 'atlas' to 'something else' and would break script
robot1 = Robot("robot1")
robot1.walk("x", 5)
robot1.walk("y", 1)
print atlas.all_occupied()
</code></pre>

<p>I am 14 years old and new to programming. this is a practice program and i canno't find this on google or yahoo. please help</p>
