class A:
    def __init__(self, txt: str):
        self.z: E = None
        self.o: E = None
        self.x: B = None
        self.t: D = None
        self.w: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: F = None
        self.z: B = None
        self.s: D = None
        self.x: C = None
        self.u: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: C = None
        self.y: C = None
        self.q: C = None
        self.txt = txt

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

m.z = f
m.o = c
m.x = n
m.t = h
m.w = g
n.u = i
n.o = h
n.p = h
n.y = m
n.x = l
n.t = l
b.v = m
b.t = i
b.z = n
b.s = h
b.x = g
b.u = f
h.p = g
c.o = g
l.p = b
l.y = b
l.q = g
f.o = g
i.p = b
i.y = b
i.q = g
g.v = m
g.t = i
g.z = n
g.s = h
g.x = b
g.u = f
assert l.q.v.w.x.v.w.s.txt == "
class A:
    def __init__(self, txt: str):
        self.z: E = None
        self.o: E = None
        self.x: B = None
        self.t: D = None
        self.w: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: F = None
        self.z: B = None
        self.s: D = None
        self.x: C = None
        self.u: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: C = None
        self.y: C = None
        self.q: C = None
        self.txt = txt

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

m.z = f
m.o = c
m.x = n
m.t = h
m.w = g
n.u = i
n.o = h
n.p = h
n.y = m
n.x = l
n.t = l
b.v = m
b.t = i
b.z = n
b.s = h
b.x = g
b.u = f
h.p = g
c.o = g
l.p = b
l.y = b
l.q = g
f.o = g
i.p = b
i.y = b
i.q = g
g.v = m
g.t = i
g.z = n
g.s = h
g.x = b
g.u = f
assert l.q.v.w.x.v.w.s.txt == "h"