class A:
    def __init__(self, txt: str):
        self.w: B = None
        self.r: D = None
        self.p: C = None
        self.t: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: H = None
        self.v: A = None
        self.t: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: B = None
        self.u: A = None
        self.x: F = None
        self.p: G = None
        self.y: G = None
        self.z: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: B = None
        self.v: C = None
        self.y: A = None
        self.x: C = None
        self.q: C = None
        self.z: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: D = None
        self.x: B = None
        self.y: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: F = None
        self.w: H = None
        self.o: F = None
        self.x: A = None
        self.s: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: A = None
        self.y: F = None
        self.t: C = None
        self.txt = txt

c = A("c")
g = B("g")
m = C("m")
e = D("e")
n = E("n")
l = F("l")
i = G("i")
f = H("f")
d = B("d")

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

class B:
    def __init__(self, txt: str):
        self.x: H = None
        self.v: A = None
        self.t: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: B = None
        self.u: A = None
        self.x: F = None
        self.p: G = None
        self.y: G = None
        self.z: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: B = None
        self.v: C = None
        self.y: A = None
        self.x: C = None
        self.q: C = None
        self.z: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: D = None
        self.x: B = None
        self.y: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: F = None
        self.w: H = None
        self.o: F = None
        self.x: A = None
        self.s: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: A = None
        self.y: F = None
        self.t: C = None
        self.txt = txt

c = A("c")
g = B("g")
m = C("m")
e = D("e")
n = E("n")
l = F("l")
i = G("i")
f = H("f")
d = B("d")

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