class A:
    def __init__(self, txt: str):
        self.y: F = None
        self.t: F = None
        self.p: B = None
        self.x: B = None
        self.q: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: A = None
        self.t: E = None
        self.o: F = None
        self.w: E = None
        self.y: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: A = None
        self.w: E = None
        self.u: A = None
        self.x: E = None
        self.v: B = None
        self.y: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: E = None
        self.r: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: A = None
        self.x: B = None
        self.u: C = None
        self.t: A = None
        self.txt = txt

c = A("c")
l = B("l")
d = C("d")
m = D("m")
i = E("i")
k = F("k")
g = B("g")
n = B("n")
b = E("b")

c.y = k
c.t = k
c.q = k
c.p = n
c.x = n
l.u = c
l.t = i
l.o = k
l.y = k
l.w = b
d.v = b
m.r = c
m.u = c
m.y = c
m.w = b
m.x = b
m.v = g
i.x = c
i.r = c
i.y = b
k.r = c
k.t = c
k.x = l
k.u = d
g.u = c
g.t = i
g.w = i
g.o = k
g.y = k
n.u = c
n.t = b
n.o = k
n.y = k
n.w = i
b.x = c
b.r = c
b.y = i
assert c.t.t.p.txt == "
class A:
    def __init__(self, txt: str):
        self.y: F = None
        self.t: F = None
        self.p: B = None
        self.x: B = None
        self.q: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: A = None
        self.t: E = None
        self.o: F = None
        self.w: E = None
        self.y: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: A = None
        self.w: E = None
        self.u: A = None
        self.x: E = None
        self.v: B = None
        self.y: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: E = None
        self.r: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: A = None
        self.x: B = None
        self.u: C = None
        self.t: A = None
        self.txt = txt

c = A("c")
l = B("l")
d = C("d")
m = D("m")
i = E("i")
k = F("k")
g = B("g")
n = B("n")
b = E("b")

c.y = k
c.t = k
c.q = k
c.p = n
c.x = n
l.u = c
l.t = i
l.o = k
l.y = k
l.w = b
d.v = b
m.r = c
m.u = c
m.y = c
m.w = b
m.x = b
m.v = g
i.x = c
i.r = c
i.y = b
k.r = c
k.t = c
k.x = l
k.u = d
g.u = c
g.t = i
g.w = i
g.o = k
g.y = k
n.u = c
n.t = b
n.o = k
n.y = k
n.w = i
b.x = c
b.r = c
b.y = i
assert c.t.t.p.txt == "n"